Go Back   CodingForums.com > :: Client side development > JavaScript programming

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 08-05-2005, 08:30 PM   PM User | #1
tadaz
New to the CF scene

 
Join Date: Aug 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
tadaz is an unknown quantity at this point
iframe.open() problem

Hello, i have a .js script with this code:

document.write('<IFRAME HEIGHT="20" WIDTH="500" SCROLLING="NO" style="border-width:0" name="iframe" ID="iframe"></IFRAME>');
function start() {
window.frames.iframe.document.open();
window.frames.iframe.document.write('<HTML>');
window.frames.iframe.document.write('<SCRIPT LANGUAGE="Javascript" src="msglib.js" type="text/javascript"></SCRIPT>');
window.frames.iframe.document.write('<BODY topmargin="0" leftmargin="0">');
window.frames.iframe.document.write("<a href=\"javascriptrevious()\">Previous</a>&nbsp;");
getmsg();
window.frames.iframe.document.write("&nbsp;<a href=\"javascript:next()\">Next</a>");
window.frames.iframe.document.write('</BODY>');
window.frames.iframe.document.write('</HTML>');
window.frames.iframe.document.close();
}

and have a problem when I write this line:

window.frames.iframe.document.write('<SCRIPT LANGUAGE="Javascript" src="msglib.js" type="text/javascript"></SCRIPT>');

the script are loading without end (I use FireFox), can I change this line with another similar, or can anyone tell me what is wrong ?

Thank you
tadaz is offline   Reply With Quote
Old 08-05-2005, 10:16 PM   PM User | #2
jscheuer1
Regular Coder

 
Join Date: Mar 2005
Location: SE PA USA
Posts: 373
Thanks: 0
Thanked 0 Times in 0 Posts
jscheuer1 is an unknown quantity at this point
Code:
window.frames.iframe.document.write('<script src="msglib.js" type="text/javascript"><'+'/'+'script>');
That should do it unless there is something strange about msglib.js.
jscheuer1 is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 09:50 PM.


Advertisement
Log in to turn off these ads.