Search the archives!
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Javascript] Optimization problem
- From: javascript@xxxxxxxxxx (Dan Costea)
- Subject: [Javascript] Optimization problem
- Date: Fri, 24 May 2002 16:39:42 -0700
This is a multi-part message in MIME format.
------=_NextPart_000_024D_01C20341.9B06D8F0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Hi,
I work with IE5.5 (the application is just for internal use, so no cross =
browser needed).=20
I have an application: the user opens an IE page, connect to the =
webserver, logs in and main page with a tree is opened. From here he can =
open some other pages. I have a lot of js code that I load on almost =
every frame of every page. The most users have the browser set "Check =
for newer ver. every time visit the page". The js code is most than =
300KB, so if the page has 5 frames, 1.5MB of js are sent from the =
webserver to the client. So, I want to make an optimization: to load =
the js code just on the top of the main page and than initialize a =
variable on every frame: top.main =3D opener.top. So, now, for calling a =
function I use: main.functionName (...); it works, BUT, my problem is: =
how to work in the function caller context? For example, if I use =
document.all['lala'] in the function, it will search for 'lala' object =
from top of the main; I want to search in the frame from where the =
function was called. Can anybody tell me how to do that?=20
I would really appreciate any help, any idea.=20
Thank you, Dan.
------=_NextPart_000_024D_01C20341.9B06D8F0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2600.0" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2> Hi,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>I work with IE5.5 (the application is =
just for=20
internal use, so no cross browser needed). </FONT></DIV>
<DIV><FONT face=3DArial size=3D2>I have an application: the user opens =
an IE page,=20
connect to the webserver, logs in and main page with a tree is opened. =
>From here=20
he can open some other pages. I have a lot of js =
code that I=20
load on almost every frame of every page. The most users have the =
browser set=20
"Check for newer ver. every time visit the page". The js code is most =
than=20
300KB, so if the page has 5 frames, 1.5MB of js are sent from the=20
webserver to the client. So, I want to make an optimization: to =
load the=20
js code just on the top of the main page and than initialize a variable =
on every=20
frame: top.main =3D opener.top. So, now, for calling a function I use:=20
main.functionName (...); it works, BUT, my problem is: how to work in =
the=20
function caller context? For example, if I use document.all['lala'] in =
the=20
function, it will search for 'lala' object from top of the main; I want =
to=20
search in the frame from where the function was called. Can anybody tell =
me how=20
to do that? </FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>I would really appreciate any help, any =
idea.=20
</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>Thank you, =
Dan.</FONT></DIV></BODY></HTML>
------=_NextPart_000_024D_01C20341.9B06D8F0--
- Prev by Date: [Javascript] createTextNode and special characters
- Next by Date: [Javascript] Status Bar Message
- Previous by thread: [Javascript] createTextNode and special characters
- Next by thread: [Javascript] Status Bar Message
- Index(es):