Hey all,
I am using dojo toolkit 9.0 and I have a registration form in a dialog box which works fine, however when the dialog box appears it doesn't display in the center of the screen. Instead it is loaded on the bottom right of the page. How can I change the position of a dialog box? All I want it to do is load (top, center)
<--script-->
function load() {
dijit.byId('registershow').show();
}
<--/script-->
<--body onload="load();"-->
<--div dojoType="dijit.Dialog" id="registershow" title="OpenOffer Registration Form"-->
...form code...
<--/div-->
Thanks
D

you may not have the
you may not have the tundra.css theme file loaded. you need to include that into your page via a link or style @import tag, and sent class="tundra" on the body (you have to for dialog, it makes itself a direct descendant of body, otherwise "any parent node" would suffice). also, the body onload="load()" should probably be replaced by dojo.addOnLoad, like this:
dojo.require("dijit.Dialog"); var load = function(){ dijit.byId('registershow').show(); }; dojo.addOnLoad(load);
setting onload="load()" may be running dijit.show() before its really all done.
My body tag
do I need the tundra class or will the soria be ok?
oh soria should be fine, if
oh soria should be fine, if you have loaded in dijit/themes/soria/soria.css ... though it is not completely ready for IE6 support :(
OK good
My style sheets
@import "jscript/dojo/dojo/resources/dojo.css";
@import "jscript/dojo/dijit/themes/tundra/tundra.css";
changed it from soria to tundra same problem. The page is longer than the browser window so I get a scrollbar on the main window. When the dialog box opens its opened in the middle of the page. I think its a bug perhaps.