Jump to content

"Sign up Page"


Buffas

Recommended Posts

Hi there...

Well I'm posting here because I'm compleatly lost... We have this small club where we need to make a "Sign Up Form" for a party... I has to contain text boxes (like name: Add: e-mal: ect...) and then some checkboxes (like lunch, dinner ect...) Finaly there has to be a submit button and when you click that you aree send to a confirmation page that sums up you input... Finaly, the data should then be send as a mail to me and to the mail address that was put on page one...

Does this makes any sence?? I would be happy for any responce to this, ex. a link to a page where i could read a toturial...

Thanks a lot...
- A
Link to comment
Share on other sites

Can't think of any tutorial, but here is a start for you - i'm sure you can work on it to understand it and make it what you want
[code]

<?php

$site_name = "whatever";
$site_email = "send_form_info@wherever.net";
$form_subject = "Form from $sitename";
$done = false;

if(isset($_POST['submit']) && !empty($_POST['message']))
{
  $message = strip_tags($_POST['message']);

  $headers = "From: $site_name <$site_email>\r\n";
  $headers .= "Reply-To: $site_name <$site_email>\r\n";
  $headers .= "Return-Path: $site_name <$site_email>\r\n";
  $headers .= "X-Mailer: PHP v".phpversion()."\r\n";

  $send_it = mail($site_email, $form_subject, $message, $headers);

  $done = true;
}


if($done == false)
{
echo <<<_HTML

<form method="post" action="{$_SERVER['PHP_SELF']}">
<input type="text" name="message" value="{$message}" />
<input type="submit" name="submit" value="Send it!" />
</form>

_HTML;
}

?>

[/code]
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.