Differences between revisions 3 and 4
Revision 3 as of 2006-04-20 07:29:55
Size: 1722
Editor: public
Revision 4 as of 2009-09-20 23:00:52
Size: 1722
Editor: localhost
Comment: converted to 1.6 markup
No differences found!


The dojo initializer is the first of a set of dojo enabled components. This is not an end user component but should allow the quick testing and hacking of dojo code.

The main reason for this component is, that it is rather complicated and not very well documented on how to do a proper initialisation of the dojo javascript subsystem. To get a quickstart a initializer tag which takes care of most of the boilerplate details can be helpful.

Some examples for the dojo initializer used in various stages of page development can be found in the dojo subdirectory of the myfaces sandbox examples.


<s:dojoInitializer require="package" provide="package" debug="true/false"  debugAtAllCosts="true/false" ..../>  
TODO add the additional initializer attributes


 <s:dojoInitializer require="dojo.widget.Editor" debug="true"/> 
 <s:dojoInitializer require="dojo.widget.DebugConsole" debugAtAllCosts="false"/>        
 <s:dojoInitializer require="dojo.widget.ResizeHandle" />       
 <s:dojoInitializer debugConsole="true" expanded="true"/>

    <script type="text/javascript" >
        function generateSomeDebuggingInfo() {
          for (var x=0; x<10; x++) {
                dojo.debug(x + ": Here is some debugging info, should be 10 new lines");                                        
        dojo.debug("also note the usage of the expanded attribute");
        dojo.debug("this attribute set to true loads the expanded version");
        dojo.debug("otherwise the non expanded version is loaded");
  <h:commandButton id="triggerdojo" onclick="javascript:generateSomeDebuggingInfo();return false;" value="[Press me for debug infos]"></h:commandButton>

DojoInitializer (last edited 2009-09-20 23:00:52 by localhost)