• Sign in to Neowin Faster!

    Create an account on Neowin to contribute and support the site.

  • 0
Sign in to follow this  

Header, something wrong with that command

Question

iCe_2x    0

I have having trouble with the header command, if I put print "blah blah" it works, yet I cant get the header to do anything

if ($password == $cpassword) {
	$url = "http://www.cchsbeta.com/custom.php?"."i=$userid";	
	header("Location: ".$url);

	exit;
	}

Share this post


Link to post
Share on other sites

2 answers to this question

Recommended Posts

  • 0
pringlex    0

That line would be better as

$url = "http://www.cchsbeta.com/custom.php?i=" . $userid;

And make sure your header is the first line of output from the script?

Share this post


Link to post
Share on other sites
  • 0
blueghost    0

i've never got header to work with putting a variable into the url. Just use html and meta-refresh

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.