CrossBrowdy - Basic tutorial


Getting started

Category chosen not found. Showing first one instead.

After downloading CrossBrowdy and decompressing it in your working folder (inside a subfolder called "CrossBrowdy"), create an HTML file with the following content:

	<script src="CrossBrowdy/CrossBrowdy.js" type="text/javascript" language="javascript"></script><!-- "type" and "language" parameters for legacy clients. -->

Then just start the CrossBrowdy framework using JavaScript language, from the same file:

	CB_init(main); //It will call the "main" function when ready.
	//This function will be called when CrossBrowdy is ready:
	function main()
		CB_console("CrossBrowdy started!");

You can create a DOM element with "CB_console" id which CrossBrowdy will use in the case that the client does not support console:

	<div id="CB_console" style="visibility:hidden; overflow:scroll;">
		<span style="font-weight:bold;">Console:</span><br />
Note that CrossBrowdy will modify the CSS "style" attribute of this DOM element if needed, setting the "display" property to "block" if it is "none" and its "visibility" property to "visible" regardless its previous value.

Check the API documentation to read more about the CB_init and CB_console functions.

Go back to Guides & Tutorials

ReturnNext »
CrossBrowdy by Joan Alba Maldonado