<?
$bgcolor = (\"#3b65b8\"); //Sidernes baggrundsfarve
$tablecolor = (\"#3b65b8\"); //Tabellernes baggrundsfarve
$linkcolor = (\"#d9e3f3\"); //Farven på alle links
$textcolor = (\"#d9e3f3\"); //Farven på alt text
if($navn && $besked) {
$besked = ereg_replace(\"<\",\"<\",$besked);
$besekd = ereg_replace(\">\",\">\",$besked);
$fil = \"gbog.txt\";
$tid = date(\"d/m Y H:i\", time());
$str = \"<tr><td colspan=\\\"2\\\"><hr size=\\\"1\\\"></td></tr>\\n<tr><td>Tid:</td><td>$tid</td></tr>\\n</tr>\\n<tr><td>Navn:</td><td>$navn</td></tr>\\n<tr><td>Email:</td><td><a href=\\\"mailto:$email\\\">$email</a></td></tr>\\n<tr><td>Icq:</td><td><a href=\\\"
http://wwp.icq.com/scripts/search.dll?to=$icq\\\">$icq</td></tr>\\n<tr><td>Hjemmeside:</td><td><a href=\\\"$hjemmeside\\\">$hjemmeside</a></td></tr>\\n<tr><td colspan=\\\"2\\\"><br>$besked</td></tr>\\n\";
$fp = fopen($fil, r);
if($fp) {
$filArray = file($fil);
$result = implode(\"\", $filArray);
$result = \"$str$result\";
fclose($fp);
}
$fp = fopen($fil, w);
if($fp) {
fputs($fp, $result);
fclose($fp);
}
header(\"location: gbog.php\");
}
?>
<html>
<head>
<title>Gæstebog</title>
<META NAME=\"Generator\" CONTENT=\"Stone\'s WebWriter 3.5\">
<style>
A:link {color: <? echo(\"$linkcolor\") ?>; text-decoration: underline; font-family: Verdana; font-size: 12 px}
A:visited {color: <? echo(\"$linkcolor\") ?>; text-decoration: underline; font-family: Verdana; font-size: 12 px}
A:hover {color: #FFFFFF; text-decoration: none; font-family: Verdana; font-size: 12 px}
A:active {color: #FFFFFF; text-decoration: none; font-family: Verdana; font-size: 12 px}
h1 {font-family: Arial Black; font-size: 25 px; color: <? echo(\"$textcolor\") ?>}
</style>
<style type=\"text/css\">
<!--
BODY { SCROLLBAR-ARROW-COLOR: #d9e3f3; SCROLLBAR-TRACK-COLOR: #3b65b8; SCROLLBAR-BASE-COLOR: #3b65b8; }
-->
</style>
</head>
<body BACKGROUND=\"nth_modern_blue_bg.gif\" bgcolor=\"<? echo(\"$bgcolor\") ?>\">
<font face=\"verdana\">
<form action=\"gbog.php\" method=\"post\">
<center>
<TABLE BORDER=\"0\">
<tr><td>Navn:</td><td><input type=\"text\" name=\"navn\"></td></tr>
<tr><td>Email:</td><td><input type=\"text\" name=\"email\"></td></tr>
<tr><td>Icq:</td><td><input type=\"text\" name=\"icq\"></td></tr>
<tr><td>Hjemmeside:</td><td><input type=\"text\" name=\"hjemmeside\" value=\"
http://\"></td></tr><tr><td colspan=\"2\"><textarea name=\"besked\" cols=\"30\" rows=\"8\"></textarea></td></tr>
<tr><td colspan=\"2\"><input type=\"submit\" name=\"skriv\" value=\"Skriv\"></td></tr>
</table>
</form>
<table WIDTH=\"50%\" border=\"0\" align=\"center\">
<?
readfile(\"gbog.txt\");
?>
</table>
</font>
</html>