Script form

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
glady weber
Forum Newbie
Posts: 1
Joined: Sat Jan 20, 2007 1:28 am

Script form

Post by glady weber »

Hi.

Could you help me with this plzz:

Where I could find a php form script that confirms the email ( like enter email again just to make sure the user has enter the right email)

Thanks for any help.
User avatar
jayshields
DevNet Resident
Posts: 1912
Joined: Mon Aug 22, 2005 12:11 pm
Location: Leeds/Manchester, England

Post by jayshields »

Maybe on hotscripts.com as part of a registration script or even a complete forum script.

What you're trying to achieve is actually very simple. Something like this is pretty much it:

Code: Select all

$email = $_POST['email']; //grab the email variable from the HTML form
$confirm_email = $_POST['cemail']; //and the confirmation email variable

if($email != $confirm_email) echo 'The email addresses you entered are not the same'; //show an error if necessary
Obviously you could do with adding some checks using functions such as isset() or is_empty() to prevent notices.
Post Reply