redho home | products | services

Programming Forums


Community for Java, PHP, Perl C, ASP and Python programmers
Thursday 18 October 2018 21:02

Ask your IT question here

blank page in FF


Goto page 1, 2  Next
 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Programming Forums -> JavaScript forum
View previous topic :: View next topic  
Author Message
Poolkop
Enthusiastic Coder


Joined: 01 Jun 2006
Posts: 123
Using firefox, I am including a javascript file using the DOM, and when it gets included, the page goes blank and it says its trying to read from the server where the js file is located -- anyone know why it would be doing this?
It works fine in IE

Reply with quote
 
Roombor
Enthusiastic Coder


Joined: 02 Jun 2006
Posts: 111
Poolkop, How are you including it?
Reply with quote
 
Poolkop
Enthusiastic Coder


Joined: 01 Jun 2006
Posts: 123
Var js = document.createElement('script'); document.getElementById('test').appendChild(js);
And there is a <div id="test"></div> at the bottom of the page

Reply with quote
 
Ikopar
Enthusiastic Coder


Joined: 26 May 2006
Posts: 168
Hmz, i'm not sure if that's allowed
Reply with quote
 
Roombor
Enthusiastic Coder


Joined: 02 Jun 2006
Posts: 111
Poolkop, You should append it to the document, not to a div.
Reply with quote
 
plantino
Enthusiastic Coder


Joined: 13 May 2006
Posts: 96
I think innerHTML is the only way to do it in FF
Reply with quote
 
Roombor
Enthusiastic Coder


Joined: 02 Jun 2006
Posts: 111
plantino, Are you sure?
I've got it working fine in firefox with DOM methods.

Reply with quote
 
Poolkop
Enthusiastic Coder


Joined: 01 Jun 2006
Posts: 123
Roombor, document.appendChild()?
Reply with quote
 
Kopilman
Enthusiastic Coder


Joined: 25 May 2006
Posts: 162
Use ajax to grab the file's source then eval() it
That's what i've done in the past

Reply with quote
 
Roombor
Enthusiastic Coder


Joined: 02 Jun 2006
Posts: 111
Http://www.webreference.com/programming/ajax_tech/
It turns out to be document.body.appendChild . My mistake.
I've only tested this running locally.
But it worked fine in firefox when I did.

Reply with quote
 
Page 1 of 2 Goto page 1, 2  Next
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Programming Forums -> JavaScript forum


Dubai Forums - Expat Help | Vegan Forum | Java Programming | 3d Design Resources | 3d Forum | 3D Jobs | 3D Textures | Paris Forum | Europe Forum
Dubai Classifieds | Dubai Property | Jobs in Dubai | Free London Classifieds | Jobs in London UK

High Quality, Custom 3d animation and Web Design solutions Royal Quality Web Hosting Services Vegetarian and Animal Rights news

© 2018 RedHo