No, this is not possible with php, since php is a server-side language, and what you want is a client-side function. So you have to do it with javascript.
You can try something like this via javascript
<script type="text/javascript" language="Javascript">window.open('http://www.example.com');</script>
source
share