The complete code for this file is below. It will only show the first entry in the database. I'm trying it on ubuntu server 12.04
<?php
/*
This file is part of TankLogger.
TankLogger is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
TankLogger is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with TankLogger; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Copyright 2002, 2003, 2004 Jason Nugent
jnugent@ns.sympatico.ca
*/
unset ($tanks);
require_once("./inc/general_functions.php");
require_once("./inc/Calendar.php");
getHeader(getcwd());
?>
<h2 class="center">Tanks that TankLogger is currently storing data for:</h2>
<?php
print getBreadCrumb();
$units = getUnits();
$tanks = getTankObjects();
foreach ($tanks AS $tank) {
print "<table cellpadding=\"3\" cellspacing=\"0\" width=\"80%\" class=\"contentTable\" align=\"center\">\n";
print "<tr><td><h3>" . $tank->tank_name . " (<a href=\"./livestock.php?tank_id=" . $tank->tank_id . "\">view livestock for this tank</a> |
<a href=\"./expenses.php?tank_id=" . $tank->tank_id . "\">view expenses for this tank</a>)</h3></td></tr>\n";
print "<tr><td>Tank Size: " . $tank->tank_size . " " . $units['size_unit'] . " (" . convertSize($tank->tank_size, $units['size_unit']) . ") </td></tr>\n";
print "<tr><td>" . $tank->tank_desc . "</td></tr>\n";
print "</table><br />\n";
}
displayVersion();
getFooter(getcwd());
?>