[thelist] Bringing windows to the foreground with javascript
Matt Warden
Matt Warden" <mwarden at odyssey-design.com
Thu, 20 Jan 2000 16:31:06 -0500
Might be a pain in the [you know what], but you can add <BODY
onLoad="window.focus();"> to each of the definitions pages. That will do
it.
I'm really not sure why your code isn't working. Seems to me that it's
valid... except that 'terms' is a local variable to the function:
term(). Why not put terms.focus(); in the function. Try that. It might
work.
--
Matt Warden
mwarden@odyssey-design.com
----- Original Message -----
From: Bart Johnston <00217289@bigred.unl.edu>
To: <thelist@lists.evolt.org>
Sent: Thursday, January 20, 2000 4:18 PM
Subject: [thelist] Bringing windows to the foreground with javascript
> hey all,
>
> I have a quick javascript question that's been buggin me for a while.
I'm
> building an online training site, and on this site there are terms
that the
> user can view definitions for in a popup window. But I want to make
sure
> that if they leave the definition window open in the background
(hidden by
> the main browser window), that the definition widow will come back to
the
> foreground if they click on another term. I thought that I would be
able to
> use focus(), but I'm pretty sure I'm getting nowhere with it.
>
> Here is the function as it is now:
>
> function term(word) {
>
> var file2open = "../glossary/" + word + ".htm";
> terms=window.open(file2open,'terms','<options>');
>
> }
>
> and here is the funtion call:
>
> <a href="javascript:term('recombinant');terms.focus()>recombinant</a>
>
>
> Any help would be greatly appreciated (my grasp of javascript isn't
what it
> should be). Thanks in advance.
>
>
> Bart Johnston
> Archrival Inc.
> Digital Design & Communication
> www.archrival.com
>
>
>
>
> _______________________________________________________
> unsubscribe+options: http://lists.evolt.org/mailman/listinfo/thelist
> tip harvester: http://lists.evolt.org/harvest/
> email archive: http://lists.evolt.org/archive/
> http://evolt.org/ Workers of the Web, evolt !
>