Lid |
|
Hey mensen van Sitemasters
Ik ben dus een forum aan het ontwikkelen en ik wil dat het zo komt te staan:
Titel Door Op
titel door datum
Titel Door Op titel door datum
Maar het staat meer zo:
Titel Door Op
titel door datum
Titel Door Op titel door datum
Ik heb al veel geprobeerd naar html gekeken maar het hoort gewoon te kloppen
Hier het eerste script forum.php.
Het gaat dus om het 2de stukje als de categorie geopent is;
<?php
include('config.php');
$catID = $_GET['catID'];
// nu de gegevens er zijn gaan we verbinding maken.
if (!$show) {
$tsel = mysql_query("select * from forumcats order by catnaam ASC");
while ($cats = mysql_fetch_array($tsel)) {
print " <div align='right'><font size='2' color='#FFFFFF'><a href='index2.php?feu=inloggen'>Inloggen</a> | <a href='index2.php?feu=registreer'>Registreren</a>
<table>
<tr>
<td width='10%' align='left' valign='top'><div align='top'><img src='$cats[catavatar]' border='0' align='top'> </div>
<br>
</td>
<td onMouseOver=\"this.bgColor='#ff9933';\" style=\"cursor:pointer;\" onMouseOut=\" this.bgColor='';\" onClick=\"window.location='index2.php?feu=forum&catID=$cats[catID]&show=yes';\"><a href=index2.php?feu=forum&catID=$cats[catID]&show=yes><img src='/graphics/catnaam.gif' border='0'><font color='#FFFFFF' size='2'><b>$cats[catnaam]</b></a><br>
<font color='#000000' size='1'><i>$cats[catbeschrijving]</i></td></tr></table>";
}
}
if ($show == yes) {
$tsel1 = mysql_query("select * from forumtopics where catID='$catID'");
while ($cats1 = mysql_fetch_array($tsel1)) {
$topics .= "
<table width='100%' cellspacing='0' cellpadding='0'>
<div align='left'>
<tr align='left' valign='top' onMouseOver=\"this.bgColor='#ff9933';\" onMouseOut=\" this.bgColor='';\">
<td valign='top' onMouseOver=\"this.bgColor='#ff9933';\" onMouseOut=\" this.bgColor='';\"><div align='left'><font size='2' face='Arial, Helvetica, sans-serif'>
<img src='/graphics/topicnaam.gif' border='0'> </font></td>
<td onMouseOver=\"this.bgColor='#ff9933';\" onMouseOut=\" this.bgColor='';\"><div align='left'><font size='2' face='Arial, Helvetica, sans-serif' color='#000000'>
<a href='index2.php?feu=topic&id=$cats1[id]&sub=reacties'><div align='left'><font size='2' face=' Arial, Helvetica, sans-serif' color='#000000'><b>$cats1[titel]</a></font></td>
<td onMouseOver=\"this.bgColor='#ff9933';\" onMouseOut=\" this.bgColor='';\"><div align='left'><font size='2' face='Arial, Helvetica, sans-serif' color='#000000'>
$cats1[door] </font></td>
<td><font size='2' face='Arial, Helvetica, sans-serif' color='#000000'>
$cats1[datum]</font></td>
</tr>
</table>
";
}
print "
<table width='100%' cellspacing='0' cellpadding='0'>
<div align='right'><font size='2' color='#FFFFFF'><a href='index2.php?feu=inloggen'>Inloggen</a> | <a href='index2.php?feu=registreer'>Registreren</a></div>
<tr>
<div align='left'>
<td width='5%' background='graphics/forum/titelbg.JPG'><div align='left><strong><font size='2' face='Verdana, Arial, Helvetica, sans-serif' color='#FFFFFF'>
</font></strong></div></td>
<td width='25%' background='graphics/forum/titelbg.JPG'><strong><font size='2' face='Verdana, Arial, Helvetica, sans-serif' color='#FFFFFF'>Titel:
</font></strong></td>
<td width='25%' background='graphics/forum/titelbg.JPG'><strong><font size='2' face='Verdana, Arial, Helvetica, sans-serif' color='#FFFFFF'>Door:
</font></strong></td>
<td width='25%' background='graphics/forum/titelbg.JPG'><strong><font size='2' face='Verdana, Arial, Helvetica, sans-serif' color='#FFFFFF'>Op:
</font></strong></div></td>
</tr>
$topics
<br>
<a href='index2.php?feu=nieuwtopic'>
<img src='graphics/forum/newtopic.gif' rf='graphics/forum/newtopicover.gif' border=0></a>
";
}
?>
<?php include('config.php'); $catID = $_GET['catID']; // nu de gegevens er zijn gaan we verbinding maken. if (!$show) { $tsel = mysql_query("select * from forumcats order by catnaam ASC"); print " <div align='right'><font size='2' color='#FFFFFF'><a href='index2.php?feu=inloggen'>Inloggen</a> | <a href='index2.php?feu=registreer'>Registreren</a> <table> <tr> <td width='10%' align='left' valign='top'><div align='top'><img src='$cats[catavatar]' border='0' align='top'> </div> <br> </td> <td onMouseOver=\"this.bgColor='#ff9933';\" style=\"cursor:pointer;\" onMouseOut=\" this.bgColor='';\" onClick=\"window.location='index2.php?feu=forum&catID=$cats[catID]&show=yes';\"><a href=index2.php?feu=forum&catID=$cats[catID]&show=yes><img src='/graphics/catnaam.gif' border='0'><font color='#FFFFFF' size='2'><b>$cats[catnaam]</b></a><br> <font color='#000000' size='1'><i>$cats[catbeschrijving]</i></td></tr></table>"; } } if ($show == yes) { $tsel1 = mysql_query("select * from forumtopics where catID='$catID'"); $topics .= " <table width='100%' cellspacing='0' cellpadding='0'> <div align='left'> <tr align='left' valign='top' onMouseOver=\"this.bgColor='#ff9933';\" onMouseOut=\" this.bgColor='';\"> <td valign='top' onMouseOver=\"this.bgColor='#ff9933';\" onMouseOut=\" this.bgColor='';\"><div align='left'><font size='2' face='Arial, Helvetica, sans-serif'> <img src='/graphics/topicnaam.gif' border='0'> </font></td> <td onMouseOver=\"this.bgColor='#ff9933';\" onMouseOut=\" this.bgColor='';\"><div align='left'><font size='2' face='Arial, Helvetica, sans-serif' color='#000000'> <a href='index2.php?feu=topic&id=$cats1[id]&sub=reacties'><div align='left'><font size='2' face=' Arial, Helvetica, sans-serif' color='#000000'><b>$cats1[titel]</a></font></td> <td onMouseOver=\"this.bgColor='#ff9933';\" onMouseOut=\" this.bgColor='';\"><div align='left'><font size='2' face='Arial, Helvetica, sans-serif' color='#000000'> $cats1[door] </font></td> <td><font size='2' face='Arial, Helvetica, sans-serif' color='#000000'> $cats1[datum]</font></td> </tr> </table> "; } <table width='100%' cellspacing='0' cellpadding='0'> <div align='right'><font size='2' color='#FFFFFF'><a href='index2.php?feu=inloggen'>Inloggen</a> | <a href='index2.php?feu=registreer'>Registreren</a></div> <tr> <div align='left'> <td width='5%' background='graphics/forum/titelbg.JPG'><div align='left><strong><font size='2' face='Verdana, Arial, Helvetica, sans-serif' color='#FFFFFF'> </font></strong></div></td> <td width='25%' background='graphics/forum/titelbg.JPG'><strong><font size='2' face='Verdana, Arial, Helvetica, sans-serif' color='#FFFFFF'>Titel: </font></strong></td> <td width='25%' background='graphics/forum/titelbg.JPG'><strong><font size='2' face='Verdana, Arial, Helvetica, sans-serif' color='#FFFFFF'>Door: </font></strong></td> <td width='25%' background='graphics/forum/titelbg.JPG'><strong><font size='2' face='Verdana, Arial, Helvetica, sans-serif' color='#FFFFFF'>Op: </font></strong></div></td> </tr> $topics <br> <a href='index2.php?feu=nieuwtopic'> <img src='graphics/forum/newtopic.gif' rf='graphics/forum/newtopicover.gif' border=0></a> "; } ?>
En ik denk dat het ook wel handig is als ik de tabel laat zien waar de include script instaat:
<table width="500" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="38" width="500"><img src="graphics/center/midb.gif" width="500" height="38"></td>
</tr>
<tr>
<td background='graphics/center/midbg.JPG'><font size="1" face="Verdana"><font color='#FFFFFF'>
<table width="90%">
<tr>
<td width="90%">
<font size='1' color="#FFFFFF" type='verdana'><div align="center"> <?php
if(!$_GET['feu'])
$_GET['feu'] = "nieuws";// deze pagina wordt standaard geopend
if(file_exists($_GET['feu'].'.php'))// php is nu de standaard extentie. die je natuurijk kan veranderen
include($_GET['feu'].'.php'); // nu wordt(als de pagina bestaad) de pagina geopend
else
include("error.php");// anders opent hij deze pagina
?></div>
<br>
</tr>
</table>
<table width="500" border="0" cellspacing="0" cellpadding="0"> <tr> <td height="38" width="500"><img src="graphics/center/midb.gif" width="500" height="38"></td> </tr> <tr> <td background='graphics/center/midbg.JPG'><font size="1" face="Verdana"><font color='#FFFFFF'> <table width="90%"> <tr> <td width="90%"> <font size='1' color="#FFFFFF" type='verdana'><div align="center"> <?php if(!$_GET['feu']) $_GET['feu'] = "nieuws";// deze pagina wordt standaard geopend if(file_exists($_GET['feu'].'.php'))// php is nu de standaard extentie. die je natuurijk kan veranderen include($_GET['feu'].'.php'); // nu wordt(als de pagina bestaad) de pagina geopend else include("error.php");// anders opent hij deze pagina ?></div> <br> </tr> </table>
Hopelijk zien jullie mijn fout, Alvast bedankt.
Sicco
|