Connecting Tech Pros Worldwide Help | Site Map

JS problems on IE

  #1  
Old March 1st, 2007, 05:45 PM
cgurwitz@gmail.com
Guest
 
Posts: n/a
I wrote some JS that works fine under Firefox, but causes IE to hang.
Can anyone give me some tips as to what the problem is in IE?
http://www.sci.brooklyn.cuny.edu/~gu...ice/index.html

Thanks!

  #2  
Old March 1st, 2007, 09:15 PM
töff 93722
Guest
 
Posts: n/a

re: JS problems on IE




Maybe because you aren't generating <HTMLtags in the content you send
to the top.right frame?

*** Sent via Developersdex http://www.developersdex.com ***
  #3  
Old March 1st, 2007, 09:25 PM
töff 93722
Guest
 
Posts: n/a

re: JS problems on IE



Oh, I think I know why ...

-- change this:
<a href="arrex1.cpp" onclick="process(1,'a',5);">

-- to this:
<a href="javascript:process(1,'a',5);">

*** Sent via Developersdex http://www.developersdex.com ***
  #4  
Old March 1st, 2007, 09:55 PM
Randy Webb
Guest
 
Posts: n/a

re: JS problems on IE


töff 93722 said the following on 3/1/2007 4:11 PM:
Quote:
Oh, I think I know why ...
Don't think too hard, you might be wrong again.
Quote:
-- change this:
<a href="arrex1.cpp" onclick="process(1,'a',5);">
>
-- to this:
<a href="javascript:process(1,'a',5);">
That is a dumb way to attempt to fix any problem. The effect is the
same, it calls a function.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
  #5  
Old March 1st, 2007, 11:05 PM
töff
Guest
 
Posts: n/a

re: JS problems on IE


Scuse me, I thought getting rid of the call to the .CPP file might help.
Please forgive me. I look forward to your own solution to the guy's
original question.

*** Sent via Developersdex http://www.developersdex.com ***
  #6  
Old March 2nd, 2007, 01:35 AM
Randy Webb
Guest
 
Posts: n/a

re: JS problems on IE


töff said the following on 3/1/2007 5:57 PM:
Quote:
Scuse me, I thought getting rid of the call to the .CPP file might help.
What are you babbling about? If you had quoted what you were replying to
it would be easier to follow.
Quote:
Please forgive me.
Sure thing.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
  #7  
Old March 2nd, 2007, 01:55 AM
töff
Guest
 
Posts: n/a

re: JS problems on IE


I don't care if you are the FAQ editor. You're a jerk. You've flamed me
twice and not even tried to help the guy who asked the question. You've
got nothing better to do, I guess. What a life.

*** Sent via Developersdex http://www.developersdex.com ***
  #8  
Old March 2nd, 2007, 02:15 AM
Randy Webb
Guest
 
Posts: n/a

re: JS problems on IE


töff said the following on 3/1/2007 8:44 PM:
Quote:
I don't care if you are the FAQ editor.
And I don't care if you are an idiot. Me being an FAQ Editor is
irrelevant, your idiocy is relevant.
Quote:
You're a jerk.
I will add that to the list of names I have been called. You are gonna
have to try harder than that though.
Quote:
You've flamed me twice
I did? Wow. If you think that was a flame you should see a real one.
Quote:
and not even tried to help the guy who asked the question.
Sure I did. I told him, indirectly, that your advice was of no use.
Quote:
You've got nothing better to do, I guess. What a life.
Actually, I do, I just choose to do this every now and then just for the
amusement.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
  #9  
Old March 2nd, 2007, 02:25 AM
Randy Webb
Guest
 
Posts: n/a

re: JS problems on IE


cgurwitz@gmail.com said the following on 3/1/2007 12:30 PM:
Quote:
I wrote some JS that works fine under Firefox, but causes IE to hang.
Can anyone give me some tips as to what the problem is in IE?
http://www.sci.brooklyn.cuny.edu/~gu...ice/index.html
IE isn't issuing a document.open before you document.write to it. Adding
a top.right.document.write() to the beginning of the function keeps IE
from hanging forever:

function process(exno,arrayname,arraydim)
{
top.right.document.open();

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
  #10  
Old March 2nd, 2007, 05:15 AM
RobG
Guest
 
Posts: n/a

re: JS problems on IE


On Mar 2, 12:11 pm, Randy Webb <HikksNotAtH...@aol.comwrote:
Quote:
cgurw...@gmail.com said the following on 3/1/2007 12:30 PM:
>
Quote:
I wrote some JS that works fine under Firefox, but causes IE to hang.
Can anyone give me some tips as to what the problem is in IE?
http://www.sci.brooklyn.cuny.edu/~gu...practice/index....
>
IE isn't issuing a document.open before you document.write to it. Adding
a top.right.document.write() to the beginning of the function keeps IE
from hanging forever:
Weird - isn't a call to document.open() *supposed* to be made
automatically when document.write() is called?

A better strategy might be to remove the use of document.write
completely.


--
Rob


  #11  
Old March 2nd, 2007, 05:55 AM
Randy Webb
Guest
 
Posts: n/a

re: JS problems on IE


RobG said the following on 3/2/2007 12:05 AM:
Quote:
On Mar 2, 12:11 pm, Randy Webb <HikksNotAtH...@aol.comwrote:
Quote:
>cgurw...@gmail.com said the following on 3/1/2007 12:30 PM:
>>
Quote:
>>I wrote some JS that works fine under Firefox, but causes IE to hang.
>>Can anyone give me some tips as to what the problem is in IE?
>>http://www.sci.brooklyn.cuny.edu/~gu...practice/index....
>IE isn't issuing a document.open before you document.write to it. Adding
>a top.right.document.write() to the beginning of the function keeps IE
>from hanging forever:
>
Weird - isn't a call to document.open() *supposed* to be made
automatically when document.write() is called?
That is my understanding. But adding the call to document.open solves
the freeze issue which points at the lack of an explicit document.open
as the culprit.
Quote:
A better strategy might be to remove the use of document.write
completely.
Absolutely.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
  #12  
Old March 5th, 2007, 04:45 PM
cgurwitz@gmail.com
Guest
 
Posts: n/a

re: JS problems on IE


Inserting document.open() does not solve the problem.
Any other ideas??
Thanks!

On Mar 2, 12:45 am, Randy Webb <HikksNotAtH...@aol.comwrote:
Quote:
RobG said the following on 3/2/2007 12:05 AM:
>
Quote:
On Mar 2, 12:11 pm, Randy Webb <HikksNotAtH...@aol.comwrote:
Quote:
cgurw...@gmail.com said the following on 3/1/2007 12:30 PM:
>
Quote:
Quote:
>I wrote someJSthat works fine under Firefox, but causesIEto hang.
>Can anyone give me some tips as to what the problem is inIE?
>>http://www.sci.brooklyn.cuny.edu/~gu...practice/index....
>IEisn't issuing a document.open before you document.write to it. Adding
a top.right.document.write() to the beginning of the function keepsIE
from hanging forever:
>
Quote:
Weird - isn't a call to document.open() *supposed* to be made
automatically when document.write() is called?
>
That is my understanding. But adding the call to document.open solves
the freeze issue which points at the lack of an explicit document.open
as the culprit.
>
Quote:
A better strategy might be to remove the use of document.write
completely.
>
Absolutely.
>
--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ -http://jibbering.com/faq/index.html
Javascript Best Practices -http://www.JavascriptToolbox.com/bestpractices/

  #13  
Old March 5th, 2007, 05:45 PM
Randy Webb
Guest
 
Posts: n/a

re: JS problems on IE


cgurwitz@gmail.com said the following on 3/5/2007 11:31 AM:
Quote:
Inserting document.open() does not solve the problem.
It solved it for me locally. If it is not solving it for you then it is
something in your setup causing it.
Quote:
Any other ideas??
Yes, don't top-post.

Answer:It destroys the order of the conversation
Question: Why?
Answer: Top-Posting.
Question: Whats the most annoying thing on Usenet?
--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
  #14  
Old March 8th, 2007, 06:45 PM
cgurwitz@gmail.com
Guest
 
Posts: n/a

re: JS problems on IE


On Mar 5, 12:34 pm, Randy Webb <HikksNotAtH...@aol.comwrote:
Quote:
cgurw...@gmail.com said the following on 3/5/2007 11:31 AM:
>
Quote:
Inserting document.open() does not solve the problem.
>
It solved it for me locally. If it is not solving it for you then it is
something in your setup causing it.
>
At this point it does work with the document.open(), but only on my
local machine.
When I access it off the server, it still makes IE hang. I did turn
off the pop-up blocker. What else could be causing this behavior?
Quote:
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ -http://jibbering.com/faq/index.html
Javascript Best Practices -http://www.JavascriptToolbox.com/bestpractices/

Closed Thread


Similar Threads
Thread Thread Starter Forum Replies Last Post
AJAX POST problems on Firefox Danny answers 10 February 7th, 2006 01:55 AM
weird error only on ie gh0st54 answers 6 November 18th, 2005 09:56 PM
reload page, document.write; external js problems robert.waters@gmail.com answers 2 November 11th, 2005 04:45 PM