[thelist] Simple JavaScript question
James Aylard
jaylard at encompass.net
Sun Aug 6 23:57:31 CDT 2000
Joel Morris wrote:
> I want to have the user click on a link and then bring up a "confirm"
> message box verifying that they really want to go to that link. Clicking
the
> "OK" should send them on their way, clicking "Cancel" should keep them on
> the same page.
Using your sample code, try this:
<script LANGUAGE="JavaScript">
<!--
function proceed2() {
return confirm("Are you sure?") ;
}
-->
</script>
<a href="http://www.citycent.com" onClick="return proceed2();">Click
here</a>
hth,
James Aylard
More information about the thelist
mailing list