feck Posted January 21, 2007 Share Posted January 21, 2007 I have a form that gets filled out from the result set of an SQL query. The user is presented with forward and back buttons to traverse the result set.The user also has the option of editing any given result set, this is then posted to another page for validation and to let the user determine if their input is correct by showing the user the input/edits.If the user decides that the edits are correct these are then posted to the database.If the user decides that no, these are not correct they have the option of going back too the form where the variables are posted back and refill out the form.Now for whatever reason the user may decide that they want to check another record by utilizing the navigation buttons described earlier.But because the form now displays posted variables, the form navigation does not work.Ive tried using unset which does destroy the variables, but because of the nature of the application, whereby the navigation buttons, once clicked refresh the page these same post variables that have been destroyed in the script are again reloaded from the browser cache.Is there anyway around this, or has anyone here come across a simiiliar problem and dealt with this some other way? Quote Link to comment https://forums.phpfreaks.com/topic/35097-unsetting-post-variables/ Share on other sites More sharing options...
virtual_odin Posted January 21, 2007 Share Posted January 21, 2007 I think you need to explain a bit more what you are trying to achieve. Quote Link to comment https://forums.phpfreaks.com/topic/35097-unsetting-post-variables/#findComment-165900 Share on other sites More sharing options...
redbullmarky Posted January 21, 2007 Share Posted January 21, 2007 with forms that involve a page refresh, i personally use a mixture of sessions (to store the data before it's confirmed) and a 'header' redirect (ie, header("Location: /wherever.php") ). This clears out any $_POST data you may have and avoids the "submit this form again?" message you get. Quote Link to comment https://forums.phpfreaks.com/topic/35097-unsetting-post-variables/#findComment-165905 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.