Can someone help me check the scripts below and see what is wrong with it. I keeps getting an error message "The page cannot be found" everytime I tried to use the Member Registration Form to add data to the Member database (PHPMySQL):
<html>
<body>
<?php
if ($submit) {
$dbh= mysql_connect("localhost", "naijacga_peter”, <“jesus17”>);
or die(‘I cannot connect to the database because:’. Mysql_error());
mysql_select_db (“naijacga_Nigeria”);
$query = "INSERT INTO member (Graduation_year, Surname, Given_name, School_attended, City, Fellowship_Attended, Gender, Title, Current_Surname, Your_name, Email, Confirm_email, Current_Country, Current_State, Current_City, Occupation, Church_Membership) VALUES ('$Graduation_year','$Surname','$Given_name','$School_Attended' ‘$Gender’, ‘$Title’, ‘$Current_Surname’ ‘$Given_name’ ‘$Email’, ‘$Confirm_email’, ‘$Current_Country’, ‘$Current_State’, ‘$Current_City’, ‘$Occupation’, ‘$Church_Membership’);
$result = mysql_query($sql);
echo "Thank you! Information entered.\n";
} else{
// display form
?>
<form method="post" action="<?php echo $_SERVER [‘PHP_SELF’?>">
Graduation Year:<input type="Text" name="Graduation_year"><br>
Surnname/Last Name:<input type="Text" name="Surname"><br>
Given Name:<input type="Text" name="Given_Name"><br>
School Attended:<input type="Text" name="School_Attended"><br>
City:<input type="Text" name="City"><br>
Fellowship Attended (if applicable):<input type="Text" name="Fellowship_Attended"><br>
Gender:<input type="Text" name="Gender"><br>
Title:<input type="Text" name="Title"><br>
Current Surname (If different):<input type="Text" name="Current_Surname"><br>
Your Name (if different):<input type="Text" name="Your_name"><br>
Email Address:<input type="Text" name="Email_Address"><br>
Confirm Email:<input type="Text" name="Confirm_Email"><br>
Current Country:<input type="Text" name="Current_Country"><br>
Current State:<input type="Text" name="Current_State"><br>
Current_City:<input type="Text" name="Current_City"><br>
Occupation:<input type="Text" name="Occupation"><br>
Church Membership:<input type="Text" name="Church_Membership"><br>
<input type="Submit" name="submit" value="Enter information">
<input type="Reset" name="Reset" Value=”Clear Information”>
</form>
<?php
} // end if
?>
</body>
</html>
Thanks in advance for your help
Petetola