471,122 Members | 1,168 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,122 software developers and data experts.

onclick parameters

I have an onclick function that pops a new window (nothing fancy) the
problem is that whenever I want to return to the page where I popped
the new window from I find that it is reloaded and has taken me to the
fist line of the page. What parameter (or anything else for that
matter) can I add in order to pop up a new window and still be in the
same place when I return to the previous page?
Thanks for your help guys
Jul 20 '05 #1
2 11070
don't use # in the href...

<a href="popup.html" target="_blank"
onclick="window.open('popup.html','','width=300,he ight=300'); return
false;">
"Luis" <va*************@msn.com> wrote in message
news:1f*************************@posting.google.co m...
I have an onclick function that pops a new window (nothing fancy) the
problem is that whenever I want to return to the page where I popped
the new window from I find that it is reloaded and has taken me to the
fist line of the page. What parameter (or anything else for that
matter) can I add in order to pop up a new window and still be in the
same place when I return to the previous page?
Thanks for your help guys

Jul 20 '05 #2
Luis wrote:
I have an onclick function that pops a new window (nothing fancy) the
problem is that whenever I want to return to the page where I popped
the new window from I find that it is reloaded and has taken me to the
fist line of the page. What parameter (or anything else for that
matter) can I add in order to pop up a new window and still be in the
same place when I return to the previous page?
Thanks for your help guys


just guessing here, but...
you probably have:

<a href="#" onClick="popup()">nothing fancy</a>

and you want to have:

<a href="some-page-for-scriptically-challenged-browsers.html"
onClick="popup(); return false;">nothing fancy</a>

the critical thing being the "return false", which tells the browser not
to try and follow the link.

arkadiusz

--
__________________________________________________ ______
enabling the empowerment and synergy of the new paradigm

Jul 20 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

8 posts views Thread by Shock | last post: by
3 posts views Thread by Zalek Bloom | last post: by
reply views Thread by LU | last post: by
3 posts views Thread by Jamie Jackson | last post: by
1 post views Thread by brianj7675 | last post: by
reply views Thread by Chumley Walrus | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.