Thanks for the quick reply.
This is the piece of code written in tag file and the tag file is just simply included in jsp page where I have to open the window.
<script type="text/javascript">
function open_window()
{
window.open("some_url","pageName","status=1,toolbar=1,top=300000,left=100000,resizable=1, scrollbars=1, toolbar=0, status=0, location=0, directories=0, menubar=0,z-lock=yes").blur();
return false;
}
if (window.addEventListener) {
window.addEventListener("unload",open_window, false);
}
else {
window.attachEvent("onunload", open_window);
}
</script>