[thelist] help

Richard Bennett mail at richardinfo.com
Mon Oct 29 07:29:03 CST 2001


Hi,
That's because you're not loading the page in a frameset.

To prevent the error you could use an object check:

objFrame.location.replace(frmSrc);
becomes.
if(objFrame)objFrame.location.replace(frmSrc);

But the code will only work if this page is loaded into a frameset, with
correctly named frames.

Seen here http://www.themonroecentre.com/ it works as it should.

Cheers,
Richard.
www.richardinfo.com


----- Original Message -----
From: "John Ward" <wardsuk at yahoo.co.uk>
To: <thelist at lists.evolt.org>
Sent: Monday, October 29, 2001 1:40 PM
Subject: [thelist] help


> HELP
>
> Please could you help me I have a java-scriptthat
> keeps coming back & saying,       location is not an
> object
> Please see below:
>
> <SCRIPT LANGUAGE=java-scriptgt;
> <!--
> function fnChangeFrame(frmName, frmSrc) {
>   var objFrame = top[frmName];
>   objFrame.location.replace(frmSrc);
> }
>
> function fnSwapMulti(frm1, frm1Src, frm2, frm2Src) {
> // assumes param 1 for frame 1, etc.
>  fnChangeFrame(frm1, frm1Src);
>  fnChangeFrame(frm2, frm2Src);
> }
>
> file://-->
> </SCRIPT>
>
> I cannot figure out what is wrong, but search engines
> don't seem to like it.
> The web site sometimes works? See web site below:
>
> http://www.themonroecentre.com/diploma.html
>
> I would be forever grateful if you could help.
>
> john
>
>
> ____________________________________________________________
> Nokia Game is on again.
> Go to http://uk.yahoo.com/nokiagame/ and join the new
> all media adventure before November 3rd.
>
> ---------------------------------------
> For unsubscribe and other options, including
> the Tip Harvester and archive of TheList go to:
> http://lists.evolt.org Workers of the Web, evolt !
>





More information about the thelist mailing list