How to keep main window in background while popup window comes up

I have a popup window that comes up when a user doesn’t have access to a certain page within my site. The problem is when a user clicks on something the popup window comes up but the bigger sized window of that popup comes up in the background as well. I am trying to have my popup window come up while the original page I clicked from is still focused/seen in the background. This is the code I currently am using, can anyone help me with what I am missing. I have a back button but I won’t need that if I want to maintain the original page in the background. Instead I will use a close button.

<html>
<head>
 <title>JavaScript Popup Example 3</title>
</head>
<script type="text/javascript">
function poponload()
{
    testwindow = window.open("", "mywindow", "location=0,status=0,scrollbars=0,width=350,height=400");
     testwindow.document.write('<h1>Get outta here!</h1><a href="#" onclick="javascript: window.opener.history.go(-1)">Parent back button</a>');
testwindow.focus();
}
</script>
<body onload="javascript: poponload()">
</body>
</html>

You have no control over what window appears in front of which.

The only way to get the control you want is to di it within the one page.