Ad block is installed and active. Please support us by disabling it.
HomeSaturday, January 20, 2018, 16:45:52
2

Preventing multiple form submissions

Tuesday, February 10, 15, 01:03:18, 3 Yaers Ago Via wain, Hits: 3288
Preventing multiple form submissions
Code:
<?php @session_start();
if(isset($_POST['submit']))
{
if (!isset($_SESSION["reload"]))
$_SESSION["reload"] = 0;
$_SESSION["reload"] = $_SESSION["reload"] + 1;
if ($_SESSION["reload"] > 1)
{
echo"Error";
die;
}
}else{
?>
<form name="maForm" action="index.php" method="post">
<input type="submit" value="Submit" name="submit">
</form>
<?php } ?>

Sign In

Sponsor

Related

Comments 1.1. :: PHP Script

This script allows your visitors to add comments to any single page on your web site.

PHP $_SESSION

Session_start creates a session or resumes the current one based on a session identifier passed via a GET or POST request, or passed via a cookie.

Smarty - Create dynamic Web Pages with PHP & MySQL

Creating Dynamic Web Pages Using Smarty and MySQL - Requirement(s): PHP Server, MySQL

Contact Us Form With Captcha

A contact us form with email and form field validation. It allows your visitors to send you an email directly from your website. Features: Captcha Image, HTML output.

PHP form with file upload

Advanced Contact Form with email and form field validation. It allows your visitors to send you an email directly from your website.

MySQL – Select from two tables

Select data from two tables, PHP MySQL

Syntax highlighting in Smarty

Syntax highlighting for Smarty - Google Code Prettify

Math Captcha V6

PHP Math Captcha Image Version 6

Captcha V1 - Free PHP Script

An anti-spam form protection image written in PHP, Version: 1.1.

Jquery PHP Contact Form

This script allows your visitors to send you an email directly from your website.
About Author

wain

Date Registered: Sun, Feb 8, 15
Last Time Online: Thu, Jun 15, 17
So far has created 115 entries.
wain
This author has not yet filled in any details.