<link rel="stylesheet" type="text/css" href="style.css">
<?
include('forb.php');

$dato = date("d/m/y h:i:s");
$klokken = date("h:i:s");
?>

<?php
$sql = "SELECT id FROM nyheder"; 
$dato = date("d/m H:i:s");
$antal1 = mysql_query("SELECT * FROM nyheder ORDER BY id DESC") or die(mysql_error());
$antal = mysql_num_rows($antal1);
print "Der er ialt skrevet <b>$antal</b> nyhed(er) på NsYoung<hr>";
$hent_beskeder = mysql_query("SELECT * FROM nyheder ORDER BY id DESC") or die(mysql_error());
while($vis = mysql_fetch_array($hent_beskeder))
{
?>

<b><?php print"$vis[overskrift]";?></b> - <a align=right href="se.php?id=<?php print"$vis[id]";?>">(Læs nyheden!</a>)<br>
<TABLE cellSpacing=0 cellPadding=0 width="500" border=0>
  <TBODY>
  <TR>
    <TD 
    style="float:left">
    <TD align=left width="500"><font size="2"><?php
$wordwrap = wordwrap($vis[nyhed],50, " <br />\n");
$wordwrap = substr($wordwrap,0,150);
$wordwrap = str_replace("<","[",$wordwrap);
$wordwrap = str_replace(">","]",$wordwrap);

echo $wordwrap;
?>... </TD></TR></TBODY></TABLE>
Nyheden er skrevet af <b><? echo "$vis[skrevet_af]";?></b> - d. <? echo $vis[dato]; ?>
<HR>
<div align=left>
<?
}
?>
<center>