afish674 Posted October 9, 2012 Share Posted October 9, 2012 I want to put within my form logic a way of loading up a new page (i.e. login area) when my login form is submitted. I wondered what is the best way to do this? I read on another forum that this can be achieved by: $url = 'thepageyouwanttogoto.html'; echo '<META HTTP-EQUIV=Refresh CONTENT="0; URL='.$url.'">'; But I seem to remember from doing some JavaScript a while back that this is not a good way of re-directing and is penalised by Google (because you could trick users onto other domains unwittingly). Link to comment Share on other sites More sharing options...
birbal Posted October 9, 2012 Share Posted October 9, 2012 use header redirection http://php.net/header Link to comment Share on other sites More sharing options...
afish674 Posted October 9, 2012 Author Share Posted October 9, 2012 I tried this and it said that it couldn't do it because my headers were already set? Link to comment Share on other sites More sharing options...
birbal Posted October 9, 2012 Share Posted October 9, 2012 check this http://w3schools.invisionzone.com/index.php?showtopic=44106&view=findpost&p=245750 Link to comment Share on other sites More sharing options...
afish674 Posted October 10, 2012 Author Share Posted October 10, 2012 Thanks! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now