otuatail Posted March 24, 2007 Share Posted March 24, 2007 simple text manipiulation question I am a data collection freak and there is a section of a website that collects data into a databse. This section opens up a new browser with it's website and adds data to the database. $link = $_REQUEST['destination']; // $link .= " " . "target=_blank"; $val = $_REQUEST['val']; mailto($val); StoreData($val); header('Location: ' . $link); I can't add the commented out line to create a new browser. have tried " ' ' " and ' " " ' Any sugestion. Des Link to comment https://forums.phpfreaks.com/topic/44141-text/ Share on other sites More sharing options...
Hell Toupee Posted March 24, 2007 Share Posted March 24, 2007 target=_blank is html, not php so it won't work. There's a Window-Target parameter with header() but if memory serves me right there's difficulties with passing information on or opening up a new window, I'd recommend just mixing the php code up with javascript and using window.open or something similar. Link to comment https://forums.phpfreaks.com/topic/44141-text/#findComment-214339 Share on other sites More sharing options...
dswain Posted March 24, 2007 Share Posted March 24, 2007 What does the data in $_REQUEST['destination'] look like? I don't think you can just append the target='_blank' code to it and it would need to be inside of the <a> tag itself. Link to comment https://forums.phpfreaks.com/topic/44141-text/#findComment-214341 Share on other sites More sharing options...
otuatail Posted March 24, 2007 Author Share Posted March 24, 2007 Thanks for that. This is odd but this part of page 1 <td class="Info"><a href="redirect_me.php?destination=http://www.changinglivesonline.org&val=Change Lives">Changing Lives on line</a></td> Page 2 <? include ("functions.inc"); session_start(); $link = $_REQUEST['destination']; // $link .= " " . "target=_blank"; $val = $_REQUEST['val']; mailto($val); StoreData($val); header('Location: ' . $link); ?> Does this help ? Link to comment https://forums.phpfreaks.com/topic/44141-text/#findComment-214354 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.