I try to make an image display in a popup window when a user click on it.
The code given below performs this function but after instead of the original page, transition to {server_path/no} “page” occurs. How to avoid this transition?
<html><head>
<script type="text/javascript">
function show_popup (url,name) {
newpop=window.open(url,name,menubar='no',location='no',scrollbars='yes',resizable='yes');
newpop.focus();
}
</script>
</head>
<body>
<img src=image.jpg height=50 onclick=show_popup("image.jpg","newpop")></img>
</body>
</html>
I think you need to make a change to ‘location’. try and set it to: