<a href="javascript:void(0)"
onClick="MyEvent('parameter1','parameter2')">link</a>
Cutter
http://www.falcon-knives.com
----Original Message Follows----
From: "Lau" <lau at goldenweb.com.au>
Reply-To: javascript at LaTech.edu
To: <javascript at LaTech.edu>
Subject: [Javascript] get link to execute script rather than load page
Date: Wed, 6 Feb 2002 18:45:34 +1100
How do I get a link to execute some script rather than load another page?
(no I don't want to use a button)
The best I can get is:
<A HREF='#' onclick='Javascript: OpenNewWindow()'>
However, this scrolls the page back up to the top - which I don't want to
happen.
I tried
<A HREF='Javascript: OpenNewWindow()'>
and
<A HREF='Javascript: void OpenNewWindow()'>
but they both give me a syntax error
Can anyone tell me how to do this?
Peace
Lau
_______________________________________________
Javascript mailing list
Javascript at LaTech.edu
https://lists.LaTech.edu/mailman/listinfo/javascript
_________________________________________________________________
Chat with friends online, try MSN Messenger: http://messenger.msn.com