andrew_ww Posted February 13, 2007 Share Posted February 13, 2007 Hello, I have the following peice of code: $deleteGoTo = "review.php"; if (isset($_SERVER['QUERY_STRING'])) { $deleteGoTo .= (strpos($deleteGoTo, '?')) ? "&" : "?"; $deleteGoTo .= $_SERVER['QUERY_STRING']; } this directs me page to a package after deleting some records. Ho I change this so that it includes parameters ? For example I get this URL: http://localhost/website/review.php? But for this instance I need it to display this: http://localhost/website/review.php?recordID=11&ID=13 Any suggestions ? I guess it'll be quite tricky to capture these two variables ? Link to comment https://forums.phpfreaks.com/topic/38301-edit-redirect-code/ Share on other sites More sharing options...
arianhojat Posted February 13, 2007 Share Posted February 13, 2007 Can u just put on review.php a hyperlink that says Delete and the link they go to is like echo '<a href="review.php?recordID='.$recordID.'&ID='.$ID; and then u can look in $_GET['recordID'] and $_GET['ID'] for the variables. and on review.php, if both of those are set, delete the record with ID=$_GET['recordID'] be4 u build the html page. OR u can set forms action <form action="get".... and when they click submit button, the query string will be built for u. and u can look in $_GET['recordID'] and $_GET['ID'] for the variables as well. and on review.php, if both of those are set, delete the record with ID=$_GET['recordID'] be4 u build the html page. Link to comment https://forums.phpfreaks.com/topic/38301-edit-redirect-code/#findComment-183643 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.