behedwin Posted March 4, 2012 Share Posted March 4, 2012 Hi I am very new to PHP Tho i have been running a phpBB forum for quite some time. I have now a need to expand the forum and i want to create a separate login page to the forum. Since i can not create my own code, i take what i find on the internet This is what i have done so far <form action="./forum/ucp.php?mode=login" method="post"> <h3><a href="./forum/ucp.php?mode=login">Login</a> • <a href="./forum/ucp.php?mode=register">Register</a></h3> <fieldset> <label for="username">Username:</label> <input type="text" name="username" id="username" size="10" title="Username" /> <label for="password">Password:</label> <input type="password" name="password" id="password" size="10" title="Password" /> <input type="submit" name="login" value="Login" /> </fieldset> <label for="autologin">Log me on automatically each visit <input type="checkbox" name="autologin" id="autologin" /></label> <input type="hidden" name="redirect" value="/index.html" /> </form> It allows me to login to the forum on a new page i have done. Tho it is not working as i want. I want it to log me in to the forum, without rederetcting me to the "login confirm" page of phpbb forum. And after im logged in i want the username/password fields to disapear since i am logged in. I need help to understand how i can do this Anyone? Quote Link to comment Share on other sites More sharing options...
guinbRo Posted March 18, 2012 Share Posted March 18, 2012 Here, this page will give you information on how to work with phpbb sessions. http://www.phpbb.com/kb/article/phpbb3-sessions-integration/ This is what you will need to do. Sessions will do everything you need to do, paired with a simple if/else statement you can choose whether or not to display a login form or a welcome back message. 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.