//start of right click disable
//end of right click
var popbackground="#FFFFFF" //specify backcolor or background image for pop window
var windowtitle="PHOTO GALLERY - HIMALAYAN SHERPA ADVENTURE"  //pop window title
function detectexist(obj){
return (typeof obj !="undefined")
}

function jkpopimage(imgpath, popwidth, popheight, textdescription){

function getpos(){
leftpos=(detectexist(window.screenLeft))? screenLeft+document.body.clientWidth/5-popwidth/1 : detectexist(window.screenX)? screenX+innerWidth/2-popwidth/2 : 0
toppos=(detectexist(window.screenTop))? screenTop+document.body.clientHeight/5-popheight/1 : detectexist(window.screenY)? screenY+innerHeight/2-popheight/2 : 5
if (window.opera){
leftpos-=screenLeft
toppos-=screenTop
}
}

getpos()
var winattributes='width='+popwidth+',height='+popheight+',resizable=no,left='+leftpos+',top='+toppos
var bodyattribute=(popbackground.indexOf(".")!=-1)? 'background="'+popbackground+'"' : 'bgcolor="'+popbackground+'"'
if (typeof jkpopwin=="undefined" || jkpopwin.closed)
jkpopwin=window.open("","",winattributes)
else{
getpos() 
jkpopwin.moveTo(leftpos, toppos)
jkpopwin.resizeTo(popwidth, popheight+30)
}
jkpopwin.document.open()
jkpopwin.document.write('</script><link href="style.css" rel="stylesheet" type="text/css"><title>'+windowtitle+'</title><body topmargin=0 rightmargin=0 leftmargin=0 bottommargin=0 '+bodyattribute+'><table align=center cellpadding="0" cellspacing="0" border="0" width="200" height="100"><tbody><tr><td height="100" align="center" valign="top"><img src="'+imgpath+'" style="margin-bottom:0em"><br></td></tr><tr><td bgcolor="#9C1304" align="left"><a href="javascript:window.close();"><img src="../images/close.gif" border=0></img></a></td></tr></tbody></table></body></html>')
jkpopwin.document.close()
jkpopwin.focus()
}

