Guest User

Untitled

a guest
Oct 23rd, 2017
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.06 KB | None | 0 0
  1. <?php
  2. $query = "Select * from $PSWinners where OwnerKey = '$ownerkey'";
  3. $result = mysql_query($query) or die(mysql_error());
  4. $num = mysql_num_rows($result);
  5.  
  6. if ($num > 0)
  7. {
  8. ?>
  9. <b>People that recieved your prize:</b>
  10. <table border = "1" class = "ownerdata" cellspacing = "1" cellpadding = "3">
  11. <tr>
  12. <th width = "34%" class = "ownerheader">Winner Name</th><th width = "33%" class = "ownerheader">Prize Selected</th><th width = "33%" class = "ownerheader">Your&nbsp;Machine</th>
  13. </tr>
  14.  
  15. <?php
  16. while( $array = mysql_fetch_assoc($result) )
  17. {
  18. $V1 = $array['WinnerName'];
  19. $V2 = $array['PrizeKey'];
  20. $V3 = $array['MachineOwner'];
  21. if ($V3 == $ownerkey) $V3 = "YES";
  22. else $V3 = "NO";
  23. $query = "Select * from $PSData where ItemKey = '$V2'";
  24. $result = mysql_query($query) or die(mysql_error());
  25. $row = mysql_fetch_array($result);
  26. $V2 = $row['ItemName'];
  27.  
  28. ?>
  29.  
  30. <tr>
  31. <td><center><?php echo $V1; ?></center></td>
  32. <td><center><?php echo $V2; ?></center></td>
  33. <td><center><?php echo $V3; ?></center></td>
  34.  
  35. </tr>
  36. </table>
  37. <?php
  38. }}
  39.  
  40. ?>
Add Comment
Please, Sign In to add comment