echo fixFieldForTextArea($riders->f_lastName . ", " . $riders->f_firstName);
    echo "</OPTION>\n";
}
?>
</SELECT>

<?php 
//-----------------------------------------------
//Location Dropdown
?>

<SELECT NAME="locID">
<?php 
echo "<OPTION VALUE='0' ";
echo ">All Locations</OPTION>\n";
$locs = new RDlocation(DBconnect());
$results = $locs->queryAll();
$currType = "";
while ($locs->parseNextRow($results)) {
    if ($locs->f_type != $currType) {
        echo "<OPTION VALUE='{$locs->f_type}' ";
        if ($currentQuery->locationID == $locs->f_type) {
            echo "SELECTED";
        }
        echo ">";
        echo fixFieldForTextArea("All " . $locs->f_type);
        echo "</OPTION>\n";
        $currType = $locs->f_type;
    }
    echo "<OPTION VALUE='{$locs->f_locationID}' ";
    if ($currentQuery->locationID == $locs->f_locationID) {
 $fixedPassword = unFixQuotes($HTTP_POST_VARS["password"]);
 $riderTest = new RDrider(DBConnect(), $units);
 if (!$riderTest->checkPerms($ride->f_riderID, $fixedPassword)) {
     $errMsg = "Invalid Password";
 }
 if (!$errMsg && $HTTP_POST_VARS["bike"] == 0) {
     //New Bike, create it
     $newBike = new RDbike(DBConnect());
     $newBike->f_bike = unFixQuotes($HTTP_POST_VARS["newBike"]);
     $newBike->f_computerSetting = (int) $HTTP_POST_VARS["computerSetting"];
     $newBike->f_riderID = $ride->f_riderID;
     $errMsg = $newBike->insertNew();
     $ride->f_bikeID = $newBike->f_bikeID;
 }
 if (!$errMsg && $HTTP_POST_VARS["location"] == 0) {
     $newLocation = new RDlocation(DBConnect());
     $newLocation->f_location = unFixQuotes($HTTP_POST_VARS["newLocation"]);
     $newLocation->f_description = unFixQuotes($HTTP_POST_VARS["newDescription"]);
     $newLocation->f_type = unFixQuotes($HTTP_POST_VARS["newLocationType"]);
     $errMsg = $newLocation->insertNew();
     $ride->f_locationID = $newLocation->f_locationID;
 }
 if (!$errMsg) {
     if ($newRide) {
         $errMsg = $ride->insertNew(unFixQuotes($HTTP_POST_VARS["password"]));
         if (!$errMsg) {
             $normMsg = "Ride Inserted";
             $rideID = $ride->f_rideID;
             $newRide = 0;
         }
     } else {