How safe would you say this is?
$pages = array("about", "help", "login");
$pagesWithId = array("shownews", "showuser", "showfile");
if (in_array($_GET['page'], $pages)) {
include('includes/'.$_GET['page'].'.php');
include('templates/'.$_GET['page'].'.html');
}
foreach ($pagesWithId as $page) {
if (ctype_digit($_GET[$page])) {
include('includes/'.$page.'.php');
include('templates/'.$page.'.html');
}
}
You see any potential threats?
Thanks