Tournaments list

For discussion of the Poker Mavens server module and other administration topics

Tournaments list

Postby narayan » Sat Feb 12, 2011 11:56 am

Hello again,
I was wandering if somebody is nice to post a code of listing the tournements on a webpage
Thank you !
narayan
 
Posts: 13
Joined: Wed Dec 08, 2010 6:04 am

Re: Tournaments list

Postby Kent Briggs » Sat Feb 12, 2011 3:02 pm

narayan wrote:I was wandering if somebody is nice to post a code of listing the tournements on a webpage


This will display a simple list with the name, buy-in, and status:

Code: Select all
<html>
<body>
<?php
  include "API.php";
  $params = "Password=" . $pw . "&Command=TournamentsList&Fields=Name,BuyIn,EntryFee,Status";
  $api = Poker_API($url,$params,true);
  if ($api["Result"] == "Error") die("Error: " . $api["Error"]);
  $n = $api["Tournaments"];
  echo "<b>Tournaments Available</b><br>";
  for($i=1;$i<=$n;$i++) echo $api["Name".$i] . " (" . $api["BuyIn".$i] . " + " . $api["EntryFee".$i] .
    ") " . $api["Status".$i] . "<br>";
?>
</body>
</html>
Kent Briggs - [email protected]
Briggs Softworks - http://www.briggsoft.com
Kent Briggs
Site Admin
 
Posts: 3788
Joined: Wed Mar 19, 2008 8:47 pm

Re: Tournaments list

Postby narayan » Sat Feb 12, 2011 3:32 pm

Perfect, exactly what I needed. Thx
narayan
 
Posts: 13
Joined: Wed Dec 08, 2010 6:04 am


Return to Site Administration

Who is online

Users browsing this forum: No registered users and 2 guests

cron