<?php session_start(); include "class.trailer.dao.php"; include_once "header.php"; $dao = new DAOtrailer(); ?> <center><b><u><font face ="Britannic Bold"><h1>Trailer</h1></font></u></b></center><br> <a href="form.trailer.php" class="btn btn-info">Add trailer</a><br> <table class="table table-striped"> <tr class ="info"> <td>#</td> <td>Make</td> <td>Year Model</td> <td>Year First Sold</td> <td>Vlf Class</td> <td>Vehicle Type</td> <td>License Type</td> <td>License Number</td> <td>Model Body Type</td> <td>MP</td> <td>MO</td> <td>AX</td> <td>WC</td> <td>Unladen G Cgw</td> <td>Vehicle Id Num</td> <td>Vehicle Use Type</td> <td>Date Issued</td> <td>Cc Alco</td> <td>Date Fee Recieved</td> <td>Picture</td>
} return true; } </script> <?php include "header.php"; include "class.trailer.dao.php"; ?> <center> <h3>Add Trailer</h3> <form name = "frmTrailer" method="POST" action="save.trailer.php" onsubmit = "return validateTrailer();"> <table cellspacing="5" cellpadding="5"> <?php if (isset($_GET["id"])) { $dao = new DAOtrailer(); $vo = $dao->get($_GET["id"]); ?> <tr> <td> Make </td> <td><input type = "text" name = "make" value= "<?php echo $vo->make; ?> "/></td> </tr> <tr> <td> Year Model </td> <td><input type = "text" name = "yr_model" value= "<?php echo $vo->yr_model; ?> "/></td>
<?php include "db.php"; include "class.trailer.dao.php"; $dao = new DAOtrailer(); if (isset($_GET["id"])) { $vo = $dao->get($_GET["id"]); $dao->del($vo); } header("Location: trailer.php");
<?php session_start(); include "db.php"; include "class.trailer.dao.php"; $dao = new DAOtrailer(); $vo = new trailer($_SESSION["uid"], $_POST["make"], $_POST["yr_model"], $_POST["yr_first_sold"], $_POST["vlf_class"], $_POST["type_veh"], $_POST["type_lic"], $_POST["license_num"], $_POST["body_type_model"], $_POST["mp"], $_POST["mo"], $_POST["ax"], $_POST["wc"], $_POST["unladen_g_cgw"], $_POST["vehicle_id_num"], $_POST["type_vehicle_use"], $_POST["date_issued"], $_POST["cc_alco"], $_POST["dt_fee_recvd"], $_POST["pic"], $_POST["registered_owner"], $_POST["amount_due"], $_POST["amount_recvd"], $_POST["amount_paid"]); if (isset($_POST["trailer_id"])) { $vo->trailer_id = $_POST["trailer_id"]; } $dao->save($vo); header("Location: trailer.php");
return false; } return true; } </script> <?php session_start(); include "header.php"; include "class.dispatch.dao.php"; include "class.company.dao.php"; include_once "db.php"; include "class.truck.dao.php"; include "class.trailer.dao.php"; $dao = new DAOtruck(); $truckList = $dao->getVehicleId($_SESSION["uid"], 1); $daoTrailer = new DAOtrailer(); $trailerList = $daoTrailer->getVehicleId($_SESSION["uid"], 1); $count = count($truckList); $daoCompany = new DAOcompany(); $companyList = $daoCompany->getCompany($_SESSION["uid"]); ?> <center> <h3>Add Dispatch</h3> <form name = "frmDispatch" method="POST" action="save.dispatch.php" onsubmit = "return validateDispatch();"> <table cellspacing="5" cellpadding="5"> <?php if (isset($_GET["id"])) { $dao = new DAOdispatch(); $vo = $dao->get($_GET["id"]); ?>