Results 1 to 18 of 18
Sep 16, 2012, 09:33 #1
- Join Date
- Jun 2012
- London, United Kingdom, United Kingdom
- 0 Post(s)
- 0 Thread(s)
PHP Form Validation 'success' message on results listings page
After adding / editing an entry on my database, I'd like a "success" message to appear on the results page.
Is there some PHP code that can check the condition of whether the previous action performed was adding / editing an entry on the database? (Obviously the results page should only display the message if this is the case but not at any other time).
In my PHP index the 'add' and 'edit' code both end with the "header('Location: .');" function so that it runs back through the index to the code that compiles data and redirects to the results page. If you 'include' the results page at the end of the add/edit code, it causes undesired multiple submissions of the new entry each time you refresh the results page.
I've got a feeling I might need to use 'sessions', which I've yet to get to grips with...
Any ideas gratefully received (but let me know if you need more info in the meantime),