checkboxes in email form

the mail() function

Moderators: macek, egami, gesf

Post Reply
User avatar
Posts: 1716
Joined: Sun Dec 29, 2002 5:03 am
Location: Portugal / Sweden

Post by gesf » Mon Sep 12, 2005 3:48 am

A checkbox is an HTML form field and it has a value too, so:

Code: Select all


if(isset($_POST['checkbox_name']) && ($_POST['checkbox_name'] == '1')){
   // Whatever you want here
   // The 1 here, is the value of your checkbox. It can be 'Yes', 'No'...
   // Whatever you want...


Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest