<?php
function Display_Prompt() {
switch ($_POST['cmd']) {
case "a":
$retur = "Hej med dig Hans";
break;
case "b":
$retur = "Hej med dig Grethe";
break;
default:
$retur = "Det er ikke fundet noget med det bogstav.";
}
return $retur;
}
?>
<html>
<head>
<title>Søgefunktion</title>
<!-- <link rel="stylesheet" type="text/css" href="css/main.css">
-->
</head>
<body onload="document.dos.cmd.focus();">
<div id="Banner">
<img src="images/banner_simple.gif" alt="banner.gif" >
</div>
Søgefunktion [Version .0a]<br>
(<a href="
http://www.w3c.org">w3c</a> .
<a href="
http://validator.w3.org/check/referer">html</a> .
<a href="
http://jigsaw.w3.org/css-validator/validator?uri=http://firestone.homeip.net/site-archive/css/main.css&warning=no&profile=css2">css</a>)' . - a 2008 Production by
<a href="
http://www.infosystems.dk">Inf0systems.</a><form action="<?php echo $_SERVER['PHP_SELF']; ?>" Method="post" Name="dos">
<table border="0">
<tr class="DosInput">
<td>z:\Games></td>
<td><input id="dosPrompt" Class="dosInput" type="text" name="cmd" maxlength="100" onKeyDown="if (window.event.keyCode==13) this.form.submit();"></td>
</tr>
</table>
<input class="SubmitBtn" type="Submit" name="send">
</form>
<?php
if (isset($_POST['send'])){
echo Display_Prompt();
}
?>
</body>
</html>