Hi,
Thanks for all the advice I've received on this subject.
I have a script that works well enough for now, see sample XHTML below.
However when the "alert" is fired I have to click on it twice to get rid of it.
I have removed chunks of code but can't seem to cure it.
Any ideas?
.....
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="
http://www.w3.org/1999/xhtml" dir="ltr">
<head>
<title></title>
</head>
<script language="_javascript_" type="text/_javascript_">
function right(e) {
var message="Sorry, this function is disabled. Borrowing the graphics from this site is a violation of copyright.";
if (navigator.appName == "Netscape" && (e.which == 3 || e.which == 2)) {
alert(message);
return false; }
else if (navigator.appName == "Microsoft Internet Explorer" &&
(event.button == 2 || event.button == 3)) {
alert(message);
return false;
}
return true;
}
document.>
document.>
if (document.layers) window.captureEvents(Event.mousedown);
if (document.layers) window.captureEvents(Event.mouseup);
window.>
window.>
</script>
<body false;">
<center>[ Try right-clicking the image and then the text link below ]
<p>
<img src="" href="http://_javascript_.internet.com/img/tjsbutton.gif" target="_blank">http://_javascript_.internet.com/img/tjsbutton.gif">
<p>
<a href="" href="http://_javascript_.internet.com" target="_blank">http://_javascript_.internet.com">Text Link</a>
<p>
<font face="arial, helvetica" size="-2">Free _javascript_s provided<br>
by <a href="" href="http://_javascript_source.com" target="_blank">http://_javascript_source.com">The _javascript_ Source</a>
</font>
</center>
<p>
</body>
</html>
Bob Poland - Fort Collins, CO
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Web-dev mailing list (
email@hidden)
Help/Unsubscribe/Update your Subscription: