I've created the following sign up script for my website. It, however, is giving me an error equal to
Parse error: syntax error, unexpected T_STRING in /home/poetgos7/public_html/signupck.php on line 32. I've tried to fix it, and nothing I seem to do works. Any ideas?
<?php
include('layout.inc');
?>
<div style="position:absolute; top:110; left:252; width:500; height:300; z-index:1;">
<p>
<?
$servername= localhost;
$dbusername = poetgos7_poetic;
$dbpassword = poetic;
$dbname = poetgos7_users;
$connection = mysql_connect($servername, $dbusername, $dbpassword);
$db = mysql_select_db($dbname, $connection);
$name = $_POST[username];
$password = $_POST[password];
$password2 = $_POST[password2];
$email = $_POST[email];
$ip = $_POST[ip];
//if else (else if)
if($name == false || $password == false || $password2 == false || $email == false){
echo "You did not fill out all the required fields. Please hit the back button and try again!";
}
if ($password != password2){
echo "The passwords did not match! Please hit the back button and try again!";
}else{
$connection = mysql_connect($servername, $dbusername, $dbpassword);
$db = mysql_select_db($dbname, $connection);
$sql = "INSET INTO members (username, password, email, ip) VALUES ($username, $password, $email, $ip);
$result = mysql_query($sql);
echo "Thank you for your registration to poetichotline.org!";
}
?>
</div>