EchoFool Posted June 15, 2009 Share Posted June 15, 2009 Is there a way in php to open a new tab similiar to how HTML does its target="_blank" in href's ? I tried using header : location but that doesn't load a new tab with the destination it just does it in the current tab. Hope you can help. Quote Link to comment Share on other sites More sharing options...
Philip Posted June 15, 2009 Share Posted June 15, 2009 You want PHP to open a new tab on a browser? Not possible, it needs to be done with JS/HTML. Quote Link to comment Share on other sites More sharing options...
EchoFool Posted June 15, 2009 Author Share Posted June 15, 2009 But doesn't JS/HTML only do it if you click a link rather than automatically? Quote Link to comment Share on other sites More sharing options...
PugJr Posted June 15, 2009 Share Posted June 15, 2009 <script type="text/javascript"> window.open( "/index.php" ) </script> That'll open up a new tab/window. Not sure if it does tabs or what. Quote Link to comment Share on other sites More sharing options...
Philip Posted June 15, 2009 Share Posted June 15, 2009 Yeah, thats another point. It's also configurable on the user's end to have target="_blank" open in a new window, or a new tab. Quote Link to comment Share on other sites More sharing options...
EchoFool Posted June 15, 2009 Author Share Posted June 15, 2009 Ok thank you Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.