I'm pretty sure OP is asking what's wrong. A couple of things I noticed:
You have no question (so far, anyway). I'm not a mind reader. I'd be happy to help, but I need to know what you're asking. Are you asking for help to fix an error? Or something else?
I see that from the variable name alone, this is (probably) a school project. However, this leads me onto point #3, which is...
Just because it is a school project does not mean you should forsake security. I see that your $sql variable holds a query vulnerable to SQL injection. If you like, read up on prepared statements or PDO.
"passowrd" should probably be "password".
You have no opening <?php tag.
Quoting from @ginerjm's excellent advice, you should always put "error_reporting(E_ALL);" and "ini_set('display_errors', '1');" on top of the file so you can see what goes wrong.
That's all off the top of my head, if I think anything else is wrong I'll come back to it.
* * *
edit: Oh, and yes, even though this is just a school project, keeping passwords and security information in the source code itself is a security hole. Assume, for instance, the site gets hacked. Now they have access to the DB itself.