Hi,
I have a regristration page made with PHP which puts data in the database, things like name, address, zip code, phone number.
The page works except for some reason ( and it is not in the code right now) the zip code, phone number default to a value of 127.
This was a value that I typed in the form the very first time I tested it. I don't know why it is still a value that is going in the database. The other problem with the form is that the pulldown menus are submitting the first value in the list not the one the user selects.
The other frustrating problem is that I created a delete button for the administration page but it is not deleting the information all that happens is that the record displayed with all its information reloads with empty values. I have the form action = to the page itself this is the code:
if (!$db) {
echo "Could not change into the database";
exit;
}
if(isset($_POST['submit'])) {
$query = "Delete FROM registerINFO_table WHERE register_id='$register_id'";
//This diplays the individual record
} else {
$query = "SELECT * FROM registerINFO_table WHERE register_id='$radiobutton'";
$result = mysql_query($query) or die("Cannot perform reg record query.");
$row = mysql_fetch_array($result);
?> <table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
--------------------------------HTML CODE DISPLAYING RECORD--
</table></center></td>
</tr>
<tr>
<td><center>
</center></td>
</tr>
</table><?php
}
?>
</body></html>
I really appreciate your comments
Thanks!
gb
😃