<?php
$include = "hjem.php";
if (isset($_GET['vis'])) {
$vis = $_GET['vis'];
$cs = explode("/", $vis);
if (!empty($cs[1])) {
$include = str_replace("/", "", $vis);
} else { $include = "$vis.php"; }
}
if (!file_exists($include)) { $include = "missing.php"; }
require_once($include);
?>
It is the $_GET you have to check for isset as that is the array with the "unknown" index.