Jump to content

[SOLVED] Redirect to previous page


sciencebear

Recommended Posts

use a header

// run mysql query
$result = mysql_query("blah....");
// redirect user
header("Location:page1.php");
exit();

I've used header before, but the users will be coming from different pages, not just one.

 

Edit: nevermind, I figured it out. I used:

header('Location:'.$HTTP_SERVER_VARS['HTTP_REFERER']);

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.