ShootingBlanks Posted September 7, 2007 Share Posted September 7, 2007 Hello... I have a system where users log in, and then they can see a list of documents. There are 15 document names listed at a time, with "next"/"prev" buttons to navigate to the next/prev set of 15 document names. When they find the one that they want to edit, they click the "EDIT" link next to the document name, and it takes them to the fields to edit. All of this works just fine... When they've submitted their edits (or if they click a "Go Back" link on that update page), it takes them back to the default "documentList.php" page. I want to know if there is a way to (when they click the "EDIT" link on the document list page, maybe?) to capture all of the stuff after "documentList.php" in the URL (starting with the "?"). That way, instead of having them always go back to the first set of 15 records, I can have the "Go Back" link send them back to the last set of 15 records that they were viewing (that would have the record that they last clicked to edit)... If there's a different way from what I described above to approach my same end-result that I want, I'm open to that suggestion as well... Does what I just said make sense? Is that possible? Session variable, maybe? I'm not sure - I'm pretty new at PHP, so I apologize if this is a stupid question. Thanks!... Quote Link to comment Share on other sites More sharing options...
lemmin Posted September 7, 2007 Share Posted September 7, 2007 $_SERVER['QUERY_STRING'] should contain that information; it doesn't start with the "?," though. Quote Link to comment Share on other sites More sharing options...
ShootingBlanks Posted September 7, 2007 Author Share Posted September 7, 2007 THANKS! That worked!!! Quote Link to comment Share on other sites More sharing options...
lemmin Posted September 7, 2007 Share Posted September 7, 2007 Did you make sure there was a GET value passed? http://domain.com will return nothing, but http://domain.com?something=somethingelse will return "something=somethingelse". 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.