<body>
<?
if(empty($_GET['id'])){
$_GET['id']="main";
}
include("files/".$_GET['id'].".php");
if (empty($file)) {
include("files/404.php");
}
?>
</body>
</html>
this will out put file as soonn as its called
or
<body>
<?
if(empty($_GET['id'])){
$_GET['id']="main";
}
$file=file_get_contents("files/".$_GET['id'].".php");
if (empty($file)) {
$file=file_get_contents("files/404.php");
}
echo $file;
?>
</body>
</html>
of course the second method wont parse any php in file unless you use eval on it but i wont be echoed untill you call it