Advertisement
Guest User

Untitled

a guest
Jun 12th, 2019
111
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. <br><h1>JOB DESCRIPTION OF THE STAFF</h1><br>
  2. <div class="table-responsive">
  3. <?php
  4. $con= mysqli_connect('localhost','root','');
  5. mysqli_select_db($con,'projectanotherdb');
  6. $sql="SELECT staff.name,staff.job_id,job.job_description FROM staff JOIN job ON staff.job_id=job.job_id";
  7. $records=mysqli_query($con,$sql);
  8.  
  9.  
  10. ?>
  11. <table class="table table-hover table-dark">
  12. <tr class="header">
  13. <th>NAME</th>
  14. <th>JOB ID</th>
  15. <th>JOB DESCRIPTION</th>
  16.  
  17. </tr>
  18. <?php
  19.  
  20. while($ques=mysqli_fetch_assoc($records))
  21. {
  22. echo "<tr>";
  23. echo "<td>".$ques['name']."</td>";
  24. echo "<td>".$ques['job_id']."</td>";
  25. echo "<td>".$ques['job_description']."</td>";
  26.  
  27. echo "</tr>";
  28. }
  29. ?>
  30. </table>
  31. </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement