ME=LEARNING PHP
I'm looking for a script that I can put on pages that will verify that a user has a current logged in session. If not, will redirect to login screen. Also, I want the session to remember an "ID" for the member to show specific details about that members info.
I wouldnt have a problem with that ID being used in the url, for example:
where 24 would be the ID of a customer stored in a table.
I'm sure I could make a script that asks for a customer to enter username and password, looks for it...if it's found, returns the ID. I'm new, but have played with that much and doesn't seem too difficult. The hard part is making it so that going directly to that url above after user is logged out would force them to log in again.
I've found some complicated script examples on the web, but don't have enough knowledge yet to be able to modify them the way I need.
Any ideas? thoughts? suggestions? complaints?
I'm looking for a script that I can put on pages that will verify that a user has a current logged in session. If not, will redirect to login screen. Also, I want the session to remember an "ID" for the member to show specific details about that members info.
I wouldnt have a problem with that ID being used in the url, for example:
where 24 would be the ID of a customer stored in a table.
I'm sure I could make a script that asks for a customer to enter username and password, looks for it...if it's found, returns the ID. I'm new, but have played with that much and doesn't seem too difficult. The hard part is making it so that going directly to that url above after user is logged out would force them to log in again.
I've found some complicated script examples on the web, but don't have enough knowledge yet to be able to modify them the way I need.
Any ideas? thoughts? suggestions? complaints?