HomeSaturday, February 25, 2017, 20:20:50
1

PHP Form Action Self Submit

Tuesday, February 10, 15, 14:10:17, 2 Yaers Ago Via wain, Hits: 2625
PHP form action self submit tutorial, requirement(s): PHP server
index.php
Code:
<?php
if(isset($_POST['submit']))
{
$filed1 = $_POST['field1'];
echo $filed1 . " ";
echo $filed2;
}else{
?>
<form method="post" action="<?php echo $_SERVER['PHP_SELF']; ?>">
<input type="text" name="field1">
<input type="hidden" name="filed2" value="hidden value">
<input type="submit" name="submit" value="Submit Form">
</form>
<?php } ?>

jonix Thursday, June 27, 2013, 08:16:05

replace:

$filed1 = $_POST[\'field1\'];

with:

$filed1 = $_POST[\'field1\'];
$filed2 = $_POST[\'field2\'];

Sign In

Web Hosting


Related

Prevent the error loading XML – libxml_use_internal_errors

libxml_use_internal_errors() allows you to disable standard libxml errors and enable user error handling.

PHP getdate

Returns an associative array containing the date information of the timestamp, or the current local time if no timestamp is given.

PHP File Create

Create and write data to a file using the php frwite function.

Process Form Data with Jquery

jQuery, Process form data

Sending HTML Email With Images - PHP Tutorial

Sending HTML Email With Images - Upload Image with PHP - Creating Dynamic Webpages Using PHP and MySQL - Select, Delete, Update..

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 Date Examples

Returns a string formatted according to the given format string using the given integer timestamp or the current time if no timestamp is given.

PHP Redirect

Header (location) redirect must be processed before any output to the browser.

Email Link

HTML email link example

PHP Form Validation

PHP form validation :: PHP tutorial, requirement(s): PHP Server
About Author

wain

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