nitation Posted August 22, 2008 Share Posted August 22, 2008 Hello guys, what am i doing wrong here $PHP_SELF?id=3 if i wanna change it to $_SERVER['PHP_SELF']?id=3 is this the best method. Link to comment https://forums.phpfreaks.com/topic/120825-_serverphp_self-error/ Share on other sites More sharing options...
JasonLewis Posted August 22, 2008 Share Posted August 22, 2008 $self = $_SERVER['PHP_SELF'] . "?id=3"; Is that what you're after. You need to explain your question a bit more, and perhaps post the error that was outputted. Link to comment https://forums.phpfreaks.com/topic/120825-_serverphp_self-error/#findComment-622814 Share on other sites More sharing options...
nitation Posted August 22, 2008 Author Share Posted August 22, 2008 @ Project This is the error Parse error: parse error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in C:\Program Files\xampp\htdocs\myfiles\czstudio\southpaw\admin\AddMainLinks.php on line 139 This is what i have on line 139 $_SERVER['PHP_SELF']?edit=$id Link to comment https://forums.phpfreaks.com/topic/120825-_serverphp_self-error/#findComment-622815 Share on other sites More sharing options...
JasonLewis Posted August 22, 2008 Share Posted August 22, 2008 Look at what I posted then. You need to make the ?edit=$id a string. Here is a better version. $_SEVER['PHP_SELF'] ."?edit=".$id; Link to comment https://forums.phpfreaks.com/topic/120825-_serverphp_self-error/#findComment-622816 Share on other sites More sharing options...
nitation Posted August 22, 2008 Author Share Posted August 22, 2008 Thanks. it worked Link to comment https://forums.phpfreaks.com/topic/120825-_serverphp_self-error/#findComment-622822 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.