Parse error: syntax error, unexpected $end in C:\xampp\htdocs\login_test\register.php on last line
2nd question. what is different between name, class, and id? if i just use id will it make difference?

<form action="register.php" method="post">
<p id = "reg_error"></p>
Firstname: <input class = "text" type="text" name="firstname"><br>
Lastname: <input class = "text" type="text" name="lastname"><br>
Username: <input class = "text" type="text" name="username"><br>
<!-- HINT -->
<p class="hint">20 characters maximum (letters and numbers only)</p>
Password: <input type="password" name="password"><br>
<!-- HINT -->
<p class="hint">20 characters maximum (letters and numbers only)</p>                  
Confirm your password: <input type="password" name="confirm_password" size="30"><br>
<!-- HINT -->
<p class="hint">20 characters maximum (letters and numbers only)</p>
Email: <input type="text" name="email"><br/>
DOB:
    <input type='text' name='dob_year' maxlength='4' size='3' value='YYYY'> / 
    <input type='text' name='dob_month' maxlength='2' size='1' value='MM'> /
    <input type='text' name='dob_day' maxlength='2' size='1' value='DD'> <br/>
Gender:
    <select name="gender">
         <option>Female</option>
        <option>Male</option>
     </select> 
<input type="submit" value="Register">
</form>
Member Avatar for diafol

Parse error: syntax error, unexpected $end in C:\xampp\htdocs\login_test\register.php on last line

Nothing to do with the code you've posted. You've only posted HTML. This is php error.

Usually means that you've left something out (; or })?

what is different between name, class, and id? if i just use id will it make difference?

More to it than this, but in short:
id can be used for js and css hooks, class likewise
name is used for identifying the form field when sent to server

This type of info will be available in most beginner's HTML tutorials. Have a Google. I don't usually direct people to W3Schools, but:

http://www.w3schools.com/html/html_getstarted.asp

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.