this was posted on another board
Code:
<?php
if ( !eregi('http', $_GET['id']) && is_numeric($_GET['id']) && file_exists($_GET['id'].'.html') )
{
include( $_GET['id'].'.html';
$next_page_id = $_GET['id'] + 1;
$prev_page_id = $_GET['id'] - 1;
}
else
{
echo "error";
}
?>