Nevermind I fixed it!!! forgot the <br> The toggle works and all, now I need help implimenting the PHP
<?php
if($_POST['honeypot'] != ''){
die("You spammer!
<p><a href=\"http://www.sourcevibe.com">« If you are not a spammer, leave checkbox blank</a></p>");
}
Here is my parse
<?php
/*
Created By Adam Khoury @ www.flashbuilding.com
-----------------------June 20, 2008-----------------------
*/
// Set error message as blank upon arrival to page
$templateerror = "";
// First we check to see if the form has been submitted
if (isset($_POST['vibe'])){
//Connect to the database through our include
include_once "account/connect_to_mysql.php";
// Filter the posted variables
$vibe = preg_replace("[^A-Za-z0-9 \. \s]", "", $_POST['vibe']); // filter everything but numbers and letters
$firstname = preg_replace("[^A-Za-z0-9 \. \s]", "", $_POST['firstname']); // filter everything but numbers and letters
$lastname = preg_replace("[^A-Za-z0-9 \. \s]", "", $_POST['lastname']); // filter everything but numbers and letters
$email = stripslashes($_POST['email']);
$email = strip_tags($email);
$email = mysql_real_escape_string($email);
$password = preg_replace("[^A-Za-z0-9 \. \s]", "", $_POST['password']); // filter everything but numbers and letters
// Check to see if the user filled all fields with
// the "Required"(*) symbol next to them in the join form
// and print out to them what they have forgotten to put in
if((!$vibe) || (!$firstname) || (!$lastname) || (!$email) || (!$password)){
$templateerror = "You did not submit the following required information!
<br /><br />";
if(!$vibe){
$templateerror .= "--- Vibe ID";include_once 'template.php';
} else if(!$firstname){
$templateerror .= "--- Your First Name";include_once 'template.php';
} else if(!$lastname){
$templateerror .= "--- Your Last Name";include_once 'template.php';
} else if(!$email){
$templateerror .= "--- Email Address";include_once 'template.php';
} else if(!$password){
$templateerror .= "--- Password"; include_once 'template.php';
}
} else {
// Database duplicate Fields Check
$sql_vibe_check = mysql_query("SELECT id FROM members WHERE vibe='$vibe' LIMIT 1");
$sql_email_check = mysql_query("SELECT id FROM members WHERE email='$email' LIMIT 1");
$vibe_check = mysql_num_rows($sql_vibe_check);
$email_check = mysql_num_rows($sql_email_check);
if ($vibe_check > 0){
$templateerror = "<u>ERROR:</u><br />Your User Name is already in use inside our system. Please try another.";include_once 'template.php';
} else if ($email_check > 0){
$templateerror = "<u>ERROR:</u><br />Your Email address is already in use inside our system. Please try another.";include_once 'template.php';
} else {
// Add MD5 Hash to the password variable
$hashedPass = md5($password);
// Add user info into the database table, claim your fields then values
$sql = mysql_query("INSERT INTO members (vibe, firstname, lastname, email, password, signupdate)
VALUES('$vibe','$firstname', '$lastname','$email','$hashedPass', now())") or die (mysql_error());
// Get the inserted ID here to use in the activation email
$id = mysql_insert_id();
// Create directory(folder) to hold each user files(pics, MP3s, etc.)
mkdir("memberFiles/$id", 0755);
// Start assembly of Email Member the activation link
$to = "$email";
// Change this to your site admin email
$from = "noreply@sourcevibe.com";
$subject = "Complete your registration";
//Begin HTML Email Message where you need to change the activation URL inside
$message = '<html>
<body bgcolor="white">
Hi ' . $firstname . ',
<br /><br />
You must complete this step to activate your Source Vibe account.
<br /><br />
Please click here to activate now >>
<a href="http://www.sourcevibe.com/account/activation.php?id=' . $id . '">
ACTIVATE NOW</a>
<br /><br />
Your Login Data is as follows:
<br /><br />
E-mail Address: ' . $email . ' <br />
Password: ' . $password . '
<br /><br />
Thank you!
</body>
</html>';
// end of message
$headers = "From: $from\r\n";
$headers .= "Content-type: text/html\r\n";
$to = "$to";
// Finally send the activation email to the member
mail($to, $subject, $message, $headers);
// Then print a message to the browser for the joiner
$templateerror = "<br><br><center><font color=\"#0071BC\"><small>Thank you for joining, one last step to verify your email identity:<center><br />
An activation link has been sent to your email: $email<br /><br />
<strong>Please check your email inbox in a moment to click on the Activation <br />
Link inside the message. After email activation you can log in.</smal>";include_once 'template.php';
exit(); // Exit so the form and page does not display, just this success message
} // Close else after database duplicate field value checks
} // Close else after missing vars check
} //Close if $_POST
?>