der er fejl i linie 9...men der står jo også noget over scriptet.
hele s koden ser sådan ud:
<?
include(\"../data/config.php\");
include(\"../data/nyhed_config.php\");
?>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv=\"Content-Type\" content=\"text/html; charset=iso-8859-1\">
<link rel=\"stylesheet\" href=\"boksstyles.css\" type=\"text/css\">
</head>
<body bgcolor=\"#FFFFFF\" text=\"#000000\" leftmargin=\"0\" topmargin=\"0\" marginwidth=\"0\" marginheight=\"0\">
<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"3\" bgcolor=\"#FF2900\" >
<?
function format($str) {
$str = stripslashes($str);
$str = htmlspecialchars($str);
$str = ereg_replace(\"((f|ht){1}
tp://[a-zA-Z0-9@:%_.~#-\\?&]+)\", \"<a href=\\\"\\\\1\\\" target=\\\"_blank\\\">\\\\1</a>\", $str);
$str = ereg_replace(\"([a-zA-Z0-9._-]+@[a-zA-Z0-9._-]+\\.[a-zA-Z0-9._-]+)\",\"<a href=\\\"mailto:\\\\1\\\">\\\\1</a>\",$str);
return $str;
}
$foresp = mysql_query(\"SELECT dato, overskrift, text, forfatter, kategori FROM nyheder ORDER BY Id DESC LIMIT 10\");
while($data = mysql_fetch_array($foresp))
{
echo \"<tr><td width=\'16\' valign=\'top\'>\";
echo \"<img src=\'grafik/$data[4]\'></td>\";
echo \"<td><span class=\'overskrift\'>$data[1] -\";
echo date(\"j/n - Y\",$data[0]);
echo \"</span><br><span class=\'btext\'>\".format($data[2]).\"<br>\";
echo \"skrevet af: $data[3]</span>\";
echo \"</td></tr>\";
}
?>
</table>
</body>
</html>