frenchpl Posted July 17, 2009 Share Posted July 17, 2009 I am newish to PHP so please be gentle with me here. I have written a whole suit of scripts to control an imaginary company. So far they are all working together. I have a datacon.php, which has the normal connect the root user stuff in it. I have head and foot scripts, again normal as far as I can see. I want to use the require once, with the datacon, just to log in the user that is trying to log in. Whatever I have tried I cannot get anything to work correctly, if I do not include the datacon.php in each script. This seems to defeat the object of having a log in for other users. I am using SESSIONS and have the session start at the top of each file. I know this is working because I am echoing the session ID from every file. Obviously I am missing something, though a few books later I am none the wiser. The other question about this lo gin stuff is this. I have created a company database which has a 'users' table, which has an 'admin' or root user in it. When I log in with the log in script I want to enable the admin user that I have created or another user and NOT the admin user in the mysql database user table. How do I do this? Thanks guys Pete Quote Link to comment Share on other sites More sharing options...
frenchpl Posted July 17, 2009 Author Share Posted July 17, 2009 Added twice by mistake Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.