My php knowledge is limited but as far as I know, after the user submit their login information, you could use php to check their credential against what's in the database. For security purposes, you could encrypt the password on the client side using javascript, and check the encrypted password against the encrypted password in the database. But either way, it could subject to the middle man attack.
Anyway, after the user is verified, you could set a session variable to be true, and then for other php pages, you could check if that variable is true or not, if true, that means the user is verified and allow to view. if not deny or direct them to login screen.
Although this way is not that secure either I think, session are capable of being hijack. You could add other security measures like store their ip address in the database and check their ip when they login, but that also could be spoof.
I think there's a better way to do the login/auth system by using https protocol, but I'm don't know much about that.