Advertisement
Guest User

Untitled

a guest
Oct 31st, 2014
182
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.61 KB | None | 0 0
  1. <h2>Staff Register</h2>
  2. <table align="justify" border="1" cellspacing="0" cellpadding="0" hspace="5px" vspace="5px">
  3.  
  4. <tr>
  5. <th nowrap="nowrap"><div align="justify">Reg Date</div></th>
  6. <th nowrap="nowrap"><div align="justify">Staff No</div></th>
  7. <th nowrap="nowrap"><div align="justify">Surname</div></th>
  8. <th nowrap="nowrap"><div align="justify">Firstname </div></th>
  9. <th nowrap="nowrap"><div align="justify">Othername </div></th>
  10. <th nowrap="nowrap"><div align="justify">Phone No</div></th>
  11. <th nowrap="nowrap"><div align="justify">Sex</div></th>
  12. <th nowrap="nowrap"><div align="justify">Age </div></th>
  13. <th nowrap="nowrap"><div align="justify">Home Address </div></th>
  14. <th nowrap="nowrap"><div align="justify">E Mail </div></th>
  15. <th nowrap="nowrap"><div align="justify">Kin Name </div></th>
  16. <th nowrap="nowrap"><div align="justify">Kin Add </div></th>
  17. <th nowrap="nowrap"><div align="justify">Kin Phone </div></th>
  18. <th nowrap="nowrap"><div align="justify">Marital Status </div></th>
  19. </tr>
  20.  
  21. <?php
  22. // Perform Inspection
  23. $confirm_select = "SELECT * FROM staff_tab WHERE (status=1) ORDER BY staffno ASC";
  24.  
  25. $query=$connection->query($confirm_select);
  26.  
  27. while($result=mysqli_fetch_array($query)){
  28. echo "<tr>";
  29. echo "<td align='justify' nowrap='nowrap'>".$result['reg_date']."</td>";
  30. echo "<td align='justify' nowrap='nowrap'>".$result['staffno']."</td>";
  31. echo "<td align='justify' nowrap='nowrap'>".$result['surname']."</td>";
  32. echo "<td align='justify' nowrap='nowrap'>".$result['firstname']."</td>";
  33. echo "<td align='justify' nowrap='nowrap'>".$result['othername']."</td>";
  34. echo "<td align='justify' nowrap='nowrap'>".$result['mobile']."</td>";
  35. echo "<td align='justify' nowrap='nowrap'>".$result['sex']."</td>";
  36. echo "<td align='justify' nowrap='nowrap'>".$result['age']."</td>";
  37. echo "<td align='justify' nowrap='nowrap'>".$result['homeadd']."</td>";
  38. echo "<td align='justify' nowrap='nowrap'>".$result['emailadd']."</td>";
  39. echo "<td align='justify' nowrap='nowrap'>".$result['nextkin']."</td>";
  40. echo "<td align='justify' nowrap='nowrap'>".$result['kinadd']."</td>";
  41. echo "<td align='justify' nowrap='nowrap'>".$result['kinphone']."</td>";
  42. echo "<td align='justify' nowrap='nowrap'>".$result['marital_status']."</td>";
  43.  
  44. }
  45. //to get total row count
  46. $res =$connection->query("SELECT staffno FROM staff_tab WHERE status=1");
  47. $pat= ($connection->affected_rows);
  48. ?>
  49. </table>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement