Just a minor adjustment to avoid missing close tags and add a default:
PHP Code:
<!DOCTYPE html>
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body>
<?php
if(!isset($_GET['page']){echo 'Hello'; }
else {
if($_GET['page'] === 'page1'){include 'page1.htm';}
else if($_GET['page'] === 'page2'){include 'page2.htm';}
else { echo 'Sorry, requested page not found.'; }
}
?>
</body>
</html>
(By the way, you can reliably use == instead of === here because $_GET values will be strings based on the kind of input. Technically they could be something else, but I don't see how they'd end up that way, unless you're manually changing the values within $_GET, which is rarely necessary [unless you're doing some kind of extra layer of URL changes with .htaccess, for example, and even then they should still be strings, as if they were the original input]. Of course === won't hurt anything, so there's no reason not to use it either I guess.)
Bookmarks