updated index.php, added 404 handling