Login   Register  
PHP Classes
elePHPant
Icontem

Antz_IntelliForm: Save submitted forms to prevent reposting warnings

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Info   View files View files (3)   DownloadInstall with Composer Download .zip   Reputation   Support forum (1)   Blog    
Last Updated Ratings Unique User Downloads Download Rankings  
2009-03-11 (5 years ago) RSS 2.0 feedStarStarStar 57%Total: 1,204 All time: 2,924 This week: 956Up
Version License PHP version Categories  
antz_intelliform 1.0GNU General Public Lice...5HTTP, PHP 5, Security
Description Author  

This class can be used to prevent form reposting warnings by saving submitted form data.

It saves the values of forms submitted using the POST method to session variables for a given length of time.

Then it makes the browser redirect to the same page forcing a new request, this time using the GET method.

The form values previously submitted using the POST method are restored from the session variables.

This way, when the user returns to this page using the browser reloading the page or using the back button the browser willing display warnings saying "Are you sure you want to resubmit the form?"

The class can also generate hidden inputs with random values also stored in session variables to prevent Cross-site request forgery exploit attempts.

Innovation Award  
PHP Programming Innovation award nominee
May 2007
Number 2


Prize: One subscription to the PDF edition of the magazine by PHP Architect
When an user needs to reload a page that was generated after submitting a form using the POST method, usually the browsers present a warning asking the user if he really wants to resubmit the form.

This kind of warnings is often annoying and confusing for the users. This class provides a solution to avoid these warnings, eventually making the user experience with the site more pleasant.

Manuel Lemos
Picture of Anthony Gallon
Name: Anthony Gallon is available for providing paid consulting. Contact Anthony Gallon .
Classes: 2 packages by
Country: New Zealand New Zealand
Age: ???
All time rank: 16129 in New Zealand New Zealand
Week rank: 1105 Up4 in New Zealand New Zealand Up
Innovation award
Innovation award
Nominee: 1x

  Files folder image Files  
File Role Description
Plain text file Antz_IntelliForm.php Class Now takes a unique identifier in ::seed() and submitted() to provide multiple forms per page
Accessible without login Plain text file example.php Example Example of usage
Plain text file IntelliForm.php Class Class file -- deprecated

 Version Control Unique User Downloads Download Rankings  
 0%Total:1,204All time:2,924
 This week:0This week:956Up
 User Ratings  
 
 All time
Utility:81%StarStarStarStarStar
Consistency:93%StarStarStarStarStar
Documentation:-
Examples:75%StarStarStarStar
Tests:-
Videos:-
Overall:57%StarStarStar
Rank:1080