[thelist] javascript pop-up problem

.jeff jeff at members.evolt.org
Mon Jul 23 19:13:42 CDT 2001


sharon,

:~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
: From: sfmalo
:
: I second Anthony's motion. The # whips
: you right back to the top.
:~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

i third anthony's motion.

:~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
: You can also use "javascript:; rather than
: "javascript://  and it will do the same
: thing. If you look closely [...]
:~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

which is exactly why i'd never recommend using the semi-colon approach -- it
doesn't stand out as more than just the javascript protocol.

:~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
: Here's a sample of what works great on my site
: for a similar situation. [...]
:
: onclick="window.open(..., ..., ..); return false;">
:~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

the downside to this approach is you don't have any control over the new
window you've created.  you can't give it focus.  you can't close it.  you
can't change the document in it, aside from using a link with a target
attribute with the same name as this new window.  it might be a quick, easy
approach, but is likely to become unwieldy once you need to use it for
something more robust or complex.  you'll do yourself a service by writing
and calling functions whenever possible.

good luck,

.jeff

http://evolt.org/
jeff at members.evolt.org
http://members.evolt.org/jeff/






More information about the thelist mailing list