photoguy
08-23-2003, 10:41 PM
I've got some photo gallery pages with thumbnails that point to this "pop up" java for close ups and wanted to modify it so there's no right click function in either IE and Netscape or any browser. I'm new and wondering if anyone can help?
Thanks
<!-- Begin POP-UP SIZES AND OPTIONS CODE
function popUpSlideshow(URL) {
var slideshow_width = 800
var slideshow_height = 600
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width='+slideshow_width+',heigh t='+slideshow_height+'');");
}
function popUp(URL) {
var view_width = 800
var view_height = 615
var look='toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=1,resizable=1,width='+view_width+',heigh t='+view_height+','
popwin=window.open("","",look)
popwin.document.open()
popwin.document.write('<title>close up</title><head>')
popwin.document.write('<link rel=StyleSheet href="coolstyle.css" type="text/css" media="screen">')
popwin.document.write('<META HTTP-EQUIV="imagetoolbar" CONTENT="no">')
popwin.document.write('<script language="JavaScript">')
popwin.document.write('function noRightClick() {')
popwin.document.write('if (event.button==2) {')
popwin.document.write('alert(\'You may not right mouse click this page.\')')
popwin.document.write('}')
popwin.document.write('}')
popwin.document.write('document.onmousedown=noRightClick')
popwin.document.write('</script>')
popwin.document.write('</head>')
popwin.document.write('<body bgcolor="#36492D" background="picts/background-pop-ups.jpg" leftmargin="0" rightmargin="0" topmargin="0" bottommargin="0" marginheight="0" marginwidth="0" class="popup">')
popwin.document.write('<TABLE cellpadding="0" cellspacing="0" border="0" width="100%" height="100%"><tr><td align="center">')
popwin.document.write('<br><center>')
popwin.document.write('<TABLE cellpadding="15" cellspacing="0" border="1" bordercolor="#FFFFFF" style="border-collapse: collapse"><tr><td>')
popwin.document.write('<img src="'+URL+'"><br>')
popwin.document.write('</td></tr></table>')
popwin.document.write('</td></tr><tr><td valign="top" align="center">')
popwin.document.write('<br><form><input type=submit value="Close" onmouseover="this.className=\'buttonon-popups\'" onmouseout="this.className=\'button-popups\'" class="button-popups" onClick=\'self.close()\'></form><br>')
popwin.document.write('</center>')
popwin.document.write('</td></tr></table>')
popwin.document.write('</body>')
popwin.document.close()
}
// End -->
<!-- Begin full screen
function fullScreen() {
window.open(location.href,'fullscreen','fullscreen,scrollbars')
}
// End -->
Thanks
<!-- Begin POP-UP SIZES AND OPTIONS CODE
function popUpSlideshow(URL) {
var slideshow_width = 800
var slideshow_height = 600
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width='+slideshow_width+',heigh t='+slideshow_height+'');");
}
function popUp(URL) {
var view_width = 800
var view_height = 615
var look='toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=1,resizable=1,width='+view_width+',heigh t='+view_height+','
popwin=window.open("","",look)
popwin.document.open()
popwin.document.write('<title>close up</title><head>')
popwin.document.write('<link rel=StyleSheet href="coolstyle.css" type="text/css" media="screen">')
popwin.document.write('<META HTTP-EQUIV="imagetoolbar" CONTENT="no">')
popwin.document.write('<script language="JavaScript">')
popwin.document.write('function noRightClick() {')
popwin.document.write('if (event.button==2) {')
popwin.document.write('alert(\'You may not right mouse click this page.\')')
popwin.document.write('}')
popwin.document.write('}')
popwin.document.write('document.onmousedown=noRightClick')
popwin.document.write('</script>')
popwin.document.write('</head>')
popwin.document.write('<body bgcolor="#36492D" background="picts/background-pop-ups.jpg" leftmargin="0" rightmargin="0" topmargin="0" bottommargin="0" marginheight="0" marginwidth="0" class="popup">')
popwin.document.write('<TABLE cellpadding="0" cellspacing="0" border="0" width="100%" height="100%"><tr><td align="center">')
popwin.document.write('<br><center>')
popwin.document.write('<TABLE cellpadding="15" cellspacing="0" border="1" bordercolor="#FFFFFF" style="border-collapse: collapse"><tr><td>')
popwin.document.write('<img src="'+URL+'"><br>')
popwin.document.write('</td></tr></table>')
popwin.document.write('</td></tr><tr><td valign="top" align="center">')
popwin.document.write('<br><form><input type=submit value="Close" onmouseover="this.className=\'buttonon-popups\'" onmouseout="this.className=\'button-popups\'" class="button-popups" onClick=\'self.close()\'></form><br>')
popwin.document.write('</center>')
popwin.document.write('</td></tr></table>')
popwin.document.write('</body>')
popwin.document.close()
}
// End -->
<!-- Begin full screen
function fullScreen() {
window.open(location.href,'fullscreen','fullscreen,scrollbars')
}
// End -->