I am having to explain the JavaScript right click coding as part of my website coursework. However, I dont actually understand the coding as I just downloaded it (its ok I put the source in my coursework!
But anyway, can someone help me with this by telling me what each line means?
I understand what this line means
var message="ENTER MESSAGE HERE";
And I also understand that the 'message' part after the variable also acts as a link back, but I dont understand this lot.
function click(e) {
if (document.all) {
if (event.button == 2) {
alert(message);
return false;
}
}
if (document.layers) {
if (e.which == 3) {
alert(message);
return false;
}
}
}
if (document.layers) {
document.captureEvents(Event.MOUSEDOWN);
}
document.onmousedown=click;
Thanks alot guys, you really have been a lot of help.
