README.md

December 4, 2022 ยท View on GitHub

Basic Error Free Redirection

Description

You know how everyone tells you to use header to redirect, you probably know by now that this only works if headers haven't already been sent. Well this way it works everytime without any errors.

More Info

You should put this in a seperate file (Eg: functions.php) and include it in your scripts or just simple put the print part in your script.

Submitted On
ByMarc 'InSp3KtaH' Giroux
LevelBeginner
User Rating4.5 (18 globes from 4 users)
CompatibilityPHP 3.0, PHP 4.0
CategoryInternet/ Browsers/ HTML
WorldPHP
Archive File

API Declarations

Use It Freely!

Source Code

<?
  function redirect($url) {
   die('<meta http-equiv="refresh" content="0;URL='.$url.'">');
  }
?>