//Connect to database server
$table = $db->prefix("fishdiary");
if($_POST["submit"])
{
$fish = $_POST["caught"];
$query = "SELECT * FROM $table WHERE caught = '$fish'";
$result = mysql_query($query);
while ($row = mysql_fetch_array($result))
{
{
$content .= "
<table border='1' cellpadding='4' cellspacing='0' style='border-collapse: collapse' align=center bordercolor='#FFFFFF' width='90%'>
<tr>
<td width='100%' colspan='4' align=center><u><b><font color=darkblue size=2>Submitted by <a href=\"javascript
:openWithSelfMain('".XOOPS_URL."/pmlite.php?send2=1&to_userid=".$uid."', 'pmlite', 450, 380);\"><u>".$uname."</u></a> on the ".showdate($date)."</font></b></u></td>
</tr>
<tr>
<td width='50%' colspan='2' align=center bgcolor=B3D6F2><u>Last New Moon:</u> <b>".$newmoon."</b></td>
<td width='50%' colspan='2' align=center bgcolor=B3D6F2><u>Days after last New Moon:</u> <b>".$moonday."</b></td>
</tr>
<tr>
<td width='30%' bgcolor=EAFBFD><u>Started Fishing:</u> <b>".$beginfishtime."</b></td>
<td width='40%' colspan='2' bgcolor=EAFBFD><u>Start Fishing Tide:</u> <b>".$beginfishtide."</b></td>
<td width='30%' bgcolor=EAFBFD><u>Temperature:</u> <b>".$peaktemp."</b></td>
</tr>
<tr>
<td width='30%' bgcolor=EAFBFD><u>Stopped Fishing:</u> <b>".$stopfishtime."</b></td>
<td width='40%' colspan='2' bgcolor=EAFBFD><u>Stop Fishing Tide:</u> <b>".$stopfishtide."</b></td>
<td width='30%' bgcolor=EAFBFD><u>Water Temperature:</u> <b>".$watertemp."</b></td>
</tr>
<tr>
<td width='30%' bgcolor=EAFBFD><u>Best Fishing Time:</u> <b>".$bestfishtime."</b></td>
<td width='40%' colspan='2' bgcolor=EAFBFD><u>Peak Fishing Tide:</u> <b>".$bestfishtide."</b></td>
<td width='30%' bgcolor=EAFBFD><u>Barometer:</u> <b>".$barometer."</b></td>
</tr>
<tr>
<td width='50%' colspan='2' align=center bgcolor=B3D6F2><u>Fish Targetted:</u> <b>".$target."</b></td>
<td width='50%' colspan='2' align=center bgcolor=B3D6F2><u>Fish Caught:</u> <b>".$caught."</b></td>
</tr>
<tr>
<td width='100%' colspan='4' bgcolor=D0FBFD><u>Location:</u><br>
<b>".$location."</b></td>
</tr>
<tr>
<td width='100%' colspan='4' bgcolor=D0FBFD><u>Successful Bait:</u><br>
<b>".$bait."</b></td>
</tr>
<tr>
<td width='100%' colspan='4' bgcolor=D0FBFD><u>Details of Trip:</u><br>
<b>".$details."</b></td>
<tr>
<td width='100%' colspan='4'> <hr></td>
</tr>
</tr>";
}
$content .= "</table>";
themecenterbox_center($title, $content);
}
}
Bookmarks