Guest User

code

a guest
Jun 11th, 2017
203
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.03 KB | None | 0 0
  1. $stmt = $mysqli->prepare("SELECT *****,*****,*****,**** FROM ***** WHERE user_id = $user_id")
  2. $stmt->bind_param('s', $user_id);
  3. $stmt->execute(); // Execute the prepared query.
  4.  
  5. // get variables from result.
  6. $stmt->bind_result($accountno ,$accountname, $brokername, $revenue,$status);
  7. $stmt->fetch();
  8.  
  9. echo "<table border='1'>
  10. <tr>
  11. <th>Account No</th>
  12. <th>Account Name</th>
  13. <th>Broker Name</th>
  14. <th>Revenue</th>
  15. </tr>";
  16.  
  17. while($row = mysqli_fetch_array($stmt))
  18. {
  19. echo "<tr>";
  20. echo "<td>" . $row['*****'] . "</td>";
  21. echo "<td>" . $row['*****'] . "</td>";
  22. echo "<td>" . $row['*****'] . "</td>";
  23. echo "<td>" . $row['*****'] . "</td>";
  24. echo "</tr>";
  25. }
  26. echo "</table>";
Add Comment
Please, Sign In to add comment