473,221 Members | 2,173 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,221 software developers and data experts.

Mozilla, document.open & memory

I'm trying to rewrite the existing window using javascript. This
works fine in IE- but in Mozilla, after I call a window.open, Mozilla
starts wandering around like an alshiemers patient and bumping into
doors.

Specificly, Mozilla seems to be losing my... functions. Or
variables. Except, I've tried alerts with dummy variables, and it
seems to find THEM just fine...
Does Mozilla start unloading existing memory right after a
document.open call? As currently structured, my script calles an open,
then skips aroudn through functions, performing a series of
document.writes before closing.
Would this problem go away if instead of performing that nonlinear
series of writes, it performed a series of additions to a string and I
just did one open/write/close at the end? (Doign so would be a neither
major nor minor alteration, so I'm asking before attempting it.)

Theological question: Who is 'right' here against the ruler of how
javascript is SUPPOSED to perform? Have I simply been benefittign from
IE's tardy/nonexistant memory cleanup, or is Mozilla overeager?
(assuming, again, it is memory cleanup I'm running into.)

Any help appreciated. I don't think I'm using anything beyond
Javascript 1.2.

-Derik

Jul 23 '05 #1
3 1945
Lee
Re********@aol.com said:

I'm trying to rewrite the existing window using javascript. This
works fine in IE- but in Mozilla, after I call a window.open, Mozilla
starts wandering around like an alshiemers patient and bumping into
doors.

Specificly, Mozilla seems to be losing my... functions. Or
variables. Except, I've tried alerts with dummy variables, and it
seems to find THEM just fine...
Does Mozilla start unloading existing memory right after a
document.open call? As currently structured, my script calles an open,
then skips aroudn through functions, performing a series of
document.writes before closing.
Would this problem go away if instead of performing that nonlinear
series of writes, it performed a series of additions to a string and I
just did one open/write/close at the end? (Doign so would be a neither
major nor minor alteration, so I'm asking before attempting it.)

Theological question: Who is 'right' here against the ruler of how
javascript is SUPPOSED to perform? Have I simply been benefittign from
IE's tardy/nonexistant memory cleanup, or is Mozilla overeager?
(assuming, again, it is memory cleanup I'm running into.)

Any help appreciated. I don't think I'm using anything beyond
Javascript 1.2.


I consider Mozilla to be right, but I doubt that the standard is that
specific. The first thing that a window.open() call does, at least in
Mozilla, is to invoke window.clear(), so yes, you'll want to accumulate
your output and do a single document.write().

Jul 23 '05 #2
Re********@aol.com wrote:
I'm trying to rewrite the existing window using javascript. This
works fine in IE- but in Mozilla, after I call a window.open, Mozilla
starts wandering around like an alshiemers patient and bumping into
doors.


For the record:

"Alzheimer’s (AHLZ-high-merz) disease is a progressive brain
disorder that gradually destroys a person’s memory and
ability to learn, reason, make judgments, communicate and
carry out daily activities."

<URL:http://www.alz.org/AboutAD/WhatIsAD.asp>
Please be a little more circumspect in the description of your
browser-related problems.

--
Rob
Jul 23 '05 #3
Lee wrote:
The first thing that a window.open() call does, at
least in Mozilla, is to invoke window.clear(), so
yes, you'll want to accumulate your output and do
a single document.write().


I did that- which makes my script much neater under the hood, thanks--
but continued to experience the same problem.

Guess what worked?
Omitting the explicit document.open() and letting mozilla use the
one implicit in document.write().

*throws tantrum*

WHHHHHHHYYYYYYYYYYYY? Why why why why WHY?

...why? I hate voodoo-scripting. "I'm not sure WHY it worked,
but when I put a space BEFORE the semi-colon..."

Why?

no, seriously, why?
-Derik

Jul 23 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: David List | last post by:
I'm having a problem using different properties of the document object in the example javascripts in my textbook with browsers that identify themselves as using the Mozilla engine. One example of...
1
by: Greg | last post by:
The following code works fine on Mozilla but generates an error* on IE, when the button calling the function is pressed and the slideshow is either on the first slide or last slide. * I can't...
3
by: kj | last post by:
This problem is driving me nuts. The code at the end of this post below works fine with IE, but fails with Mozilla. You can see it in action at http://tinyurl.com/2jvo3 With Mozilla 1.4 and...
8
by: Nicolás Lichtmaier | last post by:
Hi, some time ago I've written an article about this issue. It explain some differences in Explorer's and Mozilla's JavaScript/DOM. It has recently changed its URL, This is the new one: ...
15
by: Johan | last post by:
Hi, I've been working on the following piece of code and it works fine in IE and Opera, dut keep getting the same error in Firefox. Can anyone tell me what's wrong with this code? What I'm...
2
by: nick | last post by:
I have the following code: var w=window.open('popup.htm','','width=400,height=400'); w.opener = this; var img = w.document.getElementById('pic'); However, the img variable is always null in...
6
by: Erik Steffl | last post by:
I am trying to create a simple custom web spider using mozilla and javascript, the basic functionality is to open a website and then manipulate it using DOM (possibly opening links etc.). it...
5
by: Asterbing | last post by:
Hello, Here is a page which contains an "evoluated" (to distinguish-it from the simple one) way to hear sound on a html page event. From my memory, it worked under all major browsers, but didn't...
8
by: pitstop10 | last post by:
I use cutehtml as these are my starting days with Javascripts. The script generated by CuteHTML works in IE and Opera. It does not however work in Mozilla. its a slideshow of images. The problem with...
1
isladogs
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...
0
by: veera ravala | last post by:
ServiceNow is a powerful cloud-based platform that offers a wide range of services to help organizations manage their workflows, operations, and IT services more efficiently. At its core, ServiceNow...
0
by: VivesProcSPL | last post by:
Obviously, one of the original purposes of SQL is to make data query processing easy. The language uses many English-like terms and syntax in an effort to make it easy to learn, particularly for...
3
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 3 Jan 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). For other local times, please check World Time Buddy In...
0
by: mar23 | last post by:
Here's the situation. I have a form called frmDiceInventory with subform called subfrmDice. The subform's control source is linked to a query called qryDiceInventory. I've been trying to pick up the...
0
by: abbasky | last post by:
### Vandf component communication method one: data sharing ​ Vandf components can achieve data exchange through data sharing, state sharing, events, and other methods. Vandf's data exchange method...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: fareedcanada | last post by:
Hello I am trying to split number on their count. suppose i have 121314151617 (12cnt) then number should be split like 12,13,14,15,16,17 and if 11314151617 (11cnt) then should be split like...
0
Git
by: egorbl4 | last post by:
Скачал я git, хотел начать настройку, а там вылезло вот это Что это? Что мне с этим делать? ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.