if(basename($_SERVER[PHP_SELF]) == "config.php") {
header("location: index.php");
exit;
} Ik gebruik dit om paginas te beveiligen tegen openen, dus:
$_SERVER[PHP_SELF] = is de URL, dus bijv. http://www.ding.nl/config.php
basename($_SERVER[PHP_SELF]) = de pagina naam, dus config.php
.