[Dojo-interest] dojo.addOnload and firefox

Jean-Philippe Prade jpprade at club-internet.fr
Fri Sep 8 08:56:37 MDT 2006


It's very weird if I look in appache log after dojo finish. firefox call the
base URL with no hash

[08/Sep/2006:16:38:19 +0200] "GET /share/client/ HTTP/1.1" 200 8042
[08/Sep/2006:16:38:20 +0200] "GET /share/css/style.css HTTP/1.1" 200 9071
[08/Sep/2006:16:38:20 +0200] "GET /share/libjs/dojobuild/dojo.js HTTP/1.1"
200 201299
...
all ok image, css, js xmlhttp request
...
[08/Sep/2006:16:38:25 +0200] "GET /share/client/ HTTP/1.1" 200 8038
...
When the page is fully loaded firefox gets again all the ressource without
the hash this time.
I am investigating if it isn't coming from my php scripts but if it were ;
IE would act the same but all (dojo behaviour & apache logs) is fine on IE




Jean-Philippe Prade wrote:
> 
> Hello
> 
> I am having a problem with dojo.addOnload that fires too early with
> firefox.
> To manage the bookmarkability I parse the hash when the page is loaded and
> then I populate div like that :
> 
> function deserializeURL(){
> 	var anchors=parseAnchor(location.hash);	
> 	switch(anchors[0]){
> 		case "#search":
> 			...bind calls here ...
> 	}
> }
> 
> function init(){
> 	alert('This is getting called too early in FireFox'); 
> 	deserializeURL();
> }
> 
> dojo.addOnLoad(init);
> 
> with a url like:   http://...... /index.html#search,foo,bar
> 
> IE7 will load index.html and then populate the div.
> Firefox will populate the div first and then it will display index.html.
> 
> Here 2 screenshots 1 with FF the other with IE7 :
> 
> http://img170.imageshack.us/img170/7483/screenshot005sx6.png
> http://img170.imageshack.us/img170/8819/screenshot006oa5.png
> 
> 
> You can try it in live go to this link with IE and FF :
> 
> http://www.edumedia.fr/share/client/index.php5#anim,39
> 
> How could I make it work on firefox ?
> 
> thanks in advance
> 

-- 
View this message in context: http://www.nabble.com/dojo.addOnload-and-firefox-tf2238860.html#a6210654
Sent from the Dojo forum at Nabble.com.



More information about the Dojo-interest mailing list