Thank you so much, that is working now. However when i tried to turn my square box into a rounded box (using a tutorial on the internet) everything screws up (only background shows up). Can you please tell me what is wrong with it, the validator gave me a few minor problems but nothing that would stop it from working.
Here is the code:
CODE
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=ISO-8859-1">
<title>MOTD</title>
<style type="text/css" media="screen"><!--
body
{
color: white;
background-image:url('http://www.hiven.net/files/background.jpg')
}
#content
{
font-family: Verdana, Geneva, Arial, sans-serif;
background-color: #FFFFFF;
display: table-cell;
visibility: visible;
position: absolute;
border-width: 1px;
border-color: black;
}
/* set millions of background images */
.rbroundbox { background: url(nt.gif) repeat; }
.rbtop div { background: url(tl.gif) no-repeat top left; }
.rbtop { background: url(tr.gif) no-repeat top right; }
.rbbot div { background: url(bl.gif) no-repeat bottom left; }
.rbbot { background: url(br.gif) no-repeat bottom right; }
/* height and width stuff, width not really nessisary. */
.rbtop div, .rbtop, .rbbot div, .rbbot {
width: 100%;
height: 7px;
font-size: 1px;
}
.rbcontent { margin: 0 7px; }
.rbroundbox { width: 50%; margin: 1em auto; }
.bodytext
{
font-size: 10px;
color: #000000
}
.headline
{
font-weight: bold;
font-size: 24px
}
a:link, a:visited
{
color: #000000;
text-decoration: none
}
a:hover
{
color: red;
text-decoration: none
}
.captions
{
color: white;
font-size: 10px;
line-height: 14px;
font-family: Verdana, Geneva, Arial, sans-serif;
text-align: left
}
#header { background: #000000 url(http://www.hiven.net/forums/images/gradients/gradient_tcat.gif) no-repat;
height: 25px }
</style>
</head>
<body>
<div id="header"><img src="http://www.hiven.net/files/motdhg.gif" /></div>
<div class="rbroundbox">
<div class="rbtop"><div></div></div>
<div class="rbcontent">
<?php
$db_host = "****"; // Change this if your MySQL database host is different.
$db_name = "****"; // Change this to the name of your database.
$db_user = "****"; // Change this to your database username.
$db_pw = "****"; // Change this to your database password.
$db_prefix = "***"; //Change this to the prefix of the forum database.
$forum_url = "http://www.hiven.net/forums"; // Change this to reflect to your forum's URL.
$limit = "10"; // Number of posts displayed.
$txtlimit = "25"; // This is the character limit.
// Connecting to your database
mysql_connect($db_host, $db_user, $db_pw)
OR die ("Cannot connect to your database");
mysql_select_db($db_name) OR die("Cannot connect to your database");
if ($limit) {
$limited = "LIMIT $limit";
}
$thread_sql = mysql_query("select threadid,title,lastpost,firstpostid from $db_prefix thread where visible=1 $wheresql and open=1 $forumid order by lastpost desc $limited");
while($thread_get = mysql_fetch_array($thread_sql))
{
$lastpost = $thread_get['lastpost'];
$tid = $thread_get['threadid'];
$psql = mysql_query("SELECT postid from $db_prefix post where threadid=$tid order by postid desc");
$getp = mysql_fetch_array($psql);
$pid = $getp['postid'];
$title = $thread_get['title'];
$title = substr($title,0,$txtlimit);
echo "<li class=\"item\"><a href=\"$forum_url/showthread.php?p=$pid#post$pid\"><span>$title</span></a></li>";
}
?>
</div><!-- /rbcontent -->
<div class="rbbot"><div></div></div>
</div><!-- /rbroundbox -->
</body>
</html>