***UPDATE*** All tutorials and reference material is now being offically moved to the project's wiki page. You can find the wiki via our google project page, or directly fromhere.
I have broken up the helpers to make it easier to work with. We'll start with the main helper, Dojo.
The first thing we need to do is allow the dojo helper to be used. Add 'Dojo' to the array of helpers in the app_controller.php file. Next, we need to set up our layout. In our default layout, we need to add this snippet at the top of the page:
$dojo->css() acts similar to $dojo->link in the fact that it adds the css link to the _styleSheets array. Why use this instead of $html->css()? Well, $dojo->css does a little more than simply build the link tags. When you type in the name of the css file, without the ".css" extension on the end, it will look for that file within the resources folder of the specified project. If no project is specified, it defaults to dojo. If you specify the ".css" extension, you must specify the folder reletive to the project folder.
$dojo->theme() is works like $dojo->css, except simplyfying the css required for the theme specified. The great thing about this function is the ease of changing themes. Just change "Soria" to "Tundra", and your all set!
Now that we've prepared our layout, we must apply the settings. Insert this snippet in your header:
Most of the code should be pretty self-explanitory, so I will just go over $dojo->getReq(). This function gathers all the stored dojo.require() calls. It then places these within script tags. It is very that you call this after you call $dojo->getJFiles(). The reason is, dojo.require() requires the dojo.js file to be linked and loaded before it will work. How do you add a dojo.require() call? Easy. $dojo->req($name). I.E.:
Next we'll look at how to create an ajax content updater to your application!
Now to the fun part. Be sure you followed the tutorial above, or the following will not work. You will also need to add 'DojoAjax' and 'Form' helpers to your app_controller.php file.
Creating ajax forms is extremly easy. Start with a basic form: