stoneharry

Untitled

Jun 23rd, 2012
154
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.12 KB | None | 0 0
  1.                 $content = "<div id='votepoints'><b>Welcome, " . $_SESSION['username'] . "</b><br />Balance: $" . $this->GetVotePoints($_SESSION['user_id']) . "</div><table id='shoplist'><tr><td><b>Package</b></td><td><b>Cost</b></td><td></td></tr>";
  2.                
  3.                 if($rows != 0) {
  4.                     while($get = @mysql_fetch_array($sql)) {
  5.                         $content .= "<tr><td class=\"items\">";
  6.                    
  7.                         if($get['item_ids'] != "") {
  8.                             $item_array = explode(" ", $get['item_ids']);
  9.                    
  10.                             foreach($item_array as $item) {
  11.                                 $data = explode("|", $item);
  12.                                 $content .= $data[1] . "x" . " " . $data[0] . $data[2] . "</a><br />";
  13.                             }
  14.                         }
  15.                    
  16.                         $content .= "</td><td> $" . $get['cost'] . "</td><td>";
  17.                    
  18.                         if($get2['balance'] >= $get['cost']) {
  19.                             $content .= "<a class=\"buy\" href=\"index.php?do=senditemfinal&id=" . $get['id'] . "\">Buy</a></td></tr>";
  20.                         } else {
  21.                             $content .= "<a class=\"hidden\" href=\"javascript:\">Buy</a></td></tr>";
  22.                         }
  23.                     }
  24.                 } else {
  25.                     $content .= "<tr><td colspan=\"3\"><i>No items found in the shop</i></td></tr>";
  26.                 }
  27.                
  28.                 return $content . "</table>";
Advertisement
Add Comment
Please, Sign In to add comment