$rides = new RDride(DBconnect(), $units); $result = $rides->queryRides($currentQuery->getWhereStatement(), $start, $num + 1); $totalTime = 0; $totalDist = 0; $numRides = 0; //Not really num rides, used to see if more data is available. while ($rides->parseNextRow($result)) { $numRides++; if ($numRides > $num) { break; } echo "<TR>"; echo "<TD class=\"tbLogBody\">" . "<a href=\"showRide.php"; $tgetvars = $getVars; $tgetvars["rideID"] = $rides->f_rideID; echo encodeGet($tgetvars) . "\">" . $rides->getDatePart() . " " . $rides->getTimePart() . "</a> " . "<img width='10' height='16' src=\"" . getImgForTemp($rides->f_temperature, $units) . "\">" . "<img width='25' height='16' src=\"s" . $rides->f_sky . ".png\">" . "<img width='16' height='16' src=\"w" . $rides->f_wind . ".png\">" . "</TD>"; echo "<TD class=\"tbLogBody\">" . fixFieldForHTML($rides->f_riderID_firstName . " " . $rides->f_riderID_lastName, 0) . "</TD>"; echo "<TD class=\"tbLogBody\">" . "<img width='16' height='16' src=\"" . "templates/" . $RD_template . "/loc" . locationTypeToNumber($rides->f_locationID_type) . ".png\"> " . fixFieldForHTML($rides->f_locationID_location, 0) . "</TD>"; echo "<TD class=\"tbLogBody\">" . number_format($rides->f_distance, 2) . "</TD>"; echo "<TD class=\"tbLogBody\">{$rides->f_time}</TD>"; echo "<TD class=\"tbLogBody\">" . number_format($rides->c_avgSpeed, 2) . "</TD>"; echo "<TD class=\"tbLogBody\">{$rides->f_effortLevel}</TD>"; echo "</TR>\n"; echo "<TR>"; echo "<TD class=\"tbLogBody2\" colspan='7'>" . fixFieldForHTML(firstLine($rides->f_notes, 70), 0) . " </TD>" . "</TR>\n"; $totalTime += $rides->f_timeSecs; $totalDist += $rides->f_distance; } echo "<TR>"; echo "<TD class=\"tbLogFootHead\"><b>Sum/Avg/Max of Displayed:</b></TD>"; echo "<TD class=\"tbLogFoot\"> </TD>";
</td> </tr> <tr> <td class="tbEditHeader">Date<br> </td> <td class="tbEditBody"><input type="text" name="date" value="<?php echo $ride->getDatePart(); ?> " size="12" maxlen="15"><br> </td> <td class="tbEditHeader">Hour<br> </td> <td class="tbEditBody"><input type="text" name="hour" value="<?php echo $ride->getTimePart(); ?> " size="10" maxlen="12"><br> </td> </tr> <tr> <td class="tbEditHeader">Bike<br> </td> <td class="tbEditBody"> <select name="bike"> <option value="0">New Bike --></option> <?php foreach ($bikes as $bike) { echo "<option value=\"{$bike->f_bikeID}\""; if ($ride->f_bikeID == $bike->f_bikeID) {