ahmedkl Posted June 15, 2010 Share Posted June 15, 2010 I made a website in which i got an admin login , now what i want to do is the pages that admin when logged in can use , the other users should not be allowed to do that. For example by going to the page with the help of browser , i.e just pasting the link and get their Quote Link to comment Share on other sites More sharing options...
poleposters Posted June 15, 2010 Share Posted June 15, 2010 Hi. Can you post your login script? Your login script should create a $_SESSION variable. ie your admin username or something like that. Then at the top of every script that is admin only, you should check to see if this $_SESSION variable exists. If it doesn't, then redirect the user. Quote Link to comment Share on other sites More sharing options...
ahmedkl Posted June 15, 2010 Author Share Posted June 15, 2010 thanks poleposters i just did as you said as also found the same from google and the problem is fixed . Thankyou 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.