hihi
was wondering if anybody could help me??
Im currently running a site with images using the script:
<
<SCRIPT LANGUAGE=”JavaScript”>
<!– BEGIN
function popUp(URL) {
day = new Date();
id = day.getTime();
eval(“page” + id + ” = window.open(URL, ‘” + id + “‘, ‘toolbar=0,scrollbars=0,location=0,statusbar=0,men
ubar=0,resizable=0,width=420,height=420,left = 200,top = 50′);”);
}
// END –>
</script>
>
<end script>
in my header, and this in the body of my page to call up larger pop up images:
<
<TD ALIGN=”CENTER” WIDTH=”150″><A HREF=” javascriptopUp(‘%%URLofImages%%%%UserFieldTwo%%,
border=0′)”>%%image%%</A></TD>
<end script>
I am using this in conjunction with agora cart, fo rthose of you who may be familiar with it. (this means I have the first bit of script in my store_header.inc file, and the later in my productPage.inc file)
Unfortunatly these images are patterns which I am selling online (Patchwork Patterns to be precise), and because I am giving larger images so that customers can view them, they could also right click, copy and save them.
I’ve inserting some extra javascript into the second bit of code listed above, to stop the right click option, but it also seems to disable the pop up function all together.
Can anybody give me some advice??
?
p.s.
No right click script used was:
<
<script language=”JavaScript1.2″>
var clickmessage=”Right click disabled on images”
function disableclick(e) {
if (document.all) {
if (event.button==2||event.button==3) {
if (event.srcElement.tagName==”IMG”){
alert(clickmessage);
return false;
}
}
}
else if (document.layers) {
if (e.which == 3) {
alert(clickmessage);
return false;
}
}
else if (document.getElementById){
if (e.which==3&&e.target.tagName==”IMG”){
alert(clickmessage)
return false
}
}
}
function associateimages(){
for(i=0;i<document.images.length;i++)
document.images[i].onmousedown=disableclick;
}
if (document.all)
document.onmousedown=disableclick
else if (document.getElementById)
document.onmouseup=disableclick
else if (document.layers)
associateimages()
</script>
<end script>