4 Replies - 1205 Views - Last Post: 18 March 2003 - 03:31 PM

#1 Juravieal*  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 41
  • Joined: 18-March 03

Quick Javascript Question.

Posted 18 March 2003 - 12:48 PM

Im using the following code to pop up a window, with 2 navigation links:

<script language="Javascript"><!--
function supressError() {
return true;
}

function load(url) {
window.onerror = supressError;
opener.location.href = url;
setTimeout('self.close()',1000);
}
//--></script>

Here is the problem. The 2 pages I need this on, are framed, because the _parent frame comes from an outside source, rather than a local file. The problem, is its wanting to load the page, into the left frame, where it cant be seen, rather than the _parent window.

How do i add the _parent modifier to this code?

Thanks!

Is This A Good Question/Topic? 0
  • +

Replies To: Quick Javascript Question.

#2 Juravieal*  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 41
  • Joined: 18-March 03

Re: Quick Javascript Question.

Posted 18 March 2003 - 01:17 PM

Actually, we got it now. Just changed the "opener.location.href" line into "opener.parent.location.href" and it seems to work fine.
Was This Post Helpful? 0
  • +
  • -

#3 skyhawk133  Icon User is offline

  • Head DIC Head
  • member icon

Reputation: 1858
  • View blog
  • Posts: 20,275
  • Joined: 17-March 01

Re: Quick Javascript Question.

Posted 18 March 2003 - 02:00 PM

Slick, didn't realize you could do that... but it makes sense!
Was This Post Helpful? 0
  • +
  • -

#4 Juravieal*  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 41
  • Joined: 18-March 03

Re: Quick Javascript Question.

Posted 18 March 2003 - 03:08 PM

Hehe, actually I didnt either, I just figured I was stuck and over deadline, Ill try anything....lol. Ive really gotta brush up on my javascript skills. Our company currently doesnt do ANYTHING up to what I consider "par" for web development, and Im trying to "raise the bar" so to speak.
Was This Post Helpful? 0
  • +
  • -

#5 klewlis  Icon User is offline

  • cur tu me vexas?

Reputation: 8
  • View blog
  • Posts: 1,723
  • Joined: 09-November 01

Re: Quick Javascript Question.

Posted 18 March 2003 - 03:31 PM

Juravieal*, on Mar 18 2003, 05:08 PM, said:

Hehe, actually I didnt either, I just figured I was stuck and over deadline, Ill try anything....lol. Ive really gotta brush up on my javascript skills. Our company currently doesnt do ANYTHING up to what I consider "par" for web development, and Im trying to "raise the bar" so to speak.

ugh. i know the feeling.

i'm constantly fighting with them because they have all the regular html done by the graphic designers (!) in dreamweaver, rather than by the programmers... then the programmers just do the dynamic stuff. it's terrible.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1