Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //PHP CONNECTION AND QUERY
- <?php
- include '../session.php';
- require_once 'config.php';
- include 'header.php';
- $query = "SELECT * FROM `crew_info` WHERE `id` = ?";
- $stmt = mysqli_prepare($conn, $query);
- mysqli_stmt_bind_param($stmt, 's', $_GET['id']);
- mysqli_stmt_execute($stmt);
- mysqli_stmt_bind_result($stmt, $id, $first_name, $middle_name, $last_name, $age, $month, $day, $year, $birth_place, $gender, $martial_status, $religion, $nationality, $email_address, $address_1, $address_2, $course, $school_graduated, $remarks, $date_added, $crew_status, $image_name, $passport);
- ?>
- <table class="table table-condensed">
- <thead class="thead-inverse">
- <tr>
- <th>First Name</th>
- <th>Middle Name</th>
- <th>Last Name</th>
- <th>Age</th>
- <th>Birth Date</th>
- <th>Birth Place</th>
- <th>Gender</th>
- <th>Marital Status</th>
- <th>Religion</th>
- </thead>
- </tr>
- <tr>
- <?php
- while(mysqli_stmt_fetch($stmt)) {
- echo '<tr>';
- echo "<td class=\"col-md-2\">".sprintf("%s", $first_name)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $middle_name)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $last_name)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $age)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s %s %s", $month, $day, $year)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $birth_place)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $gender)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $martial_status)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $religion)."</td>";
- echo '</tr>';
- }
- ?>
- </tr>
- <thead class="thead-inverse">
- <tr>
- <th>Nationality</th>
- <th>Email Address</th>
- <th>Address 1</th>
- <th>Address 2</th>
- <th>Course</th>
- <th>School Graduated</th>
- <th>Remarks</th>
- <th>Date Added</th>
- <th>Status</th>
- </thead>
- </tr>
- <?php
- while(mysqli_stmt_fetch($stmt)) {
- echo '<tr>';
- echo "<td class=\"col-md-2\">".sprintf("%s", $nationality)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $email_address)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $address_1)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $address_2)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $course)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $school_graduated)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $remarks)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $date_added)."</td>";
- echo "<td class=\"col-md-2\">".sprintf("%s", $crew_status)."</td>";
- echo '</tr>';
- }
- ?>
- </table>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement