-4

Hey this is my first question on the site. I own a website, https://www.antetech.org and I am trying to implement a login/register feature. The html works fine, and connects to the database fine. But when i mess with varibles, i get a http 500 error. Can someone help? Here's the php part that messes things up:

if(isset($_POST['submit_btn']))
{
    $username = $_POST['username']
    $password = $_POST['password']
    $cpassword = $_POST['cpassword']
}

Please note when this part is not included, the site loads fine. I'm following a tutorial and it works fine for him.

Matt Raines
  • 4,149
  • 8
  • 31
  • 34

1 Answers1

1

Turn on error reporting, this will help you with your errors.

Add this to the beginning of your script :

ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);

You should find out pretty fast that you missed the semi-columns at the end of your lines :

<?php
if(isset($_POST['submit_btn']))
 {
    $username = $_POST['username'];
    $password = $_POST['password'];
    $cpassword = $_POST['cpassword'];
}
?>
Lou
  • 866
  • 5
  • 14