this is a common problem. i get that kind of error when i accidently miss a semicolon or $ on a variable. it just means that your syntax is wrong.
in your case, on line 11, you missed a semicolon
($query = "SELECT * FROM login WHERE name = '$name' AND password = '$password'")
meaning the line after it would get confused. so with semicolon problems, it always tells you the line after it had problems
----------------------------
http://aeonofdarkness.com