Updated index.php to include Login Funtionality

Included if-conditionals for login functionality.