Three ways to redirect PHP

  • 2020-05-30 19:44:20
  • OfStack


//1
header("Location: index.php"); 
//2
echo '<scr and pt type="text/javascript">
window.location = "index.php";
</scr and pt>'; 
//3
echo "<META HTTP-EQUIV="Refresh" CONTENT="0; URL=index.php">";


Related articles: