0

this probably has a simple solution but i cant seem to see whats wrong with it

<?php

//Form Data
//error seems to occur here
echo "<h1>Registration</h1>";


$submit = $_POST['submit'];

$fullname = $_POST['fullname'];
$username = $_POST['username'];
$password = $_POST['password'];
$repeat_password = $_POST['repeat_password'];


if ($submit)
{
   
}
?>
//between these two points

<html>
<form action='register.php' method='POST'>
<table>
    <tr>
        <td>
        Choose a Username:
        </td>
        
        <td>
        <input type='text' name="username">
        </td>
    </tr>
    <tr>
        <td>
        Password:
        </td>
        <td><input type='password' name="password">
        </td>
    </tr>
    <tr>    
        <td>
        Repeat Your Password:
        </td>
        <td><input type='password' name="repeat_password">
        </td>
    </tr>
    <tr>
        <td>
        Your Full Name:
        </td>
        <td><input type='text' name="name">
        </td>
    </tr>
        </table>
        <p><input type='submit' name='submit'></p>

</form>

</html>
3
Contributors
2
Replies
3
Views
7 Years
Discussion Span
Last Post by Zagga
0

Hi jamesyrawr,

As Pritaeas suggested, you have an error with one of your post values.

The form is giving an element the name of "name" but you are trying to get the value "fullname" from the $_POST array.

Try changing line 53 from <input type='text' name="name"> To <input type='text' name="fullname"> .


Hope this helps.
Zagga

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.