Jump to content


Arcade Champions Portal Block


  • You cannot reply to this topic
1 reply to this topic

#1 cwpc

    Newbie

  • Members
  • Pip
  • 2 posts

Posted 06 September 2006 - 11:58 AM

I had Followed the instructions at Invisionize to add the recent arcade champions. However since the upgrade to Arcade 3.0.0 this block has stopped working.

Any help is greatly appreciated

Thanks

Quote

QUOTE(romaanjam @ May 30 2006, 01:30 PM)


If you are looking for recent arcade champs, here is the code: put this in a custom block.

CODE
<tr><th width="50%" nowrap="nowrap">Game Name</th><th width="30%" nowrap="nowrap">Champ</th><th width="20%" nowrap="nowrap">New Score</th></tr>
<?
$champer = mysql_query("SELECT c.*, g.gcat, cat.password FROM ibf_games_champs AS c, ibf_games_list AS g, ibf_games_cats AS cat WHERE c.champ_gid=g.gid AND g.gcat=cat.c_id AND trim(password)='' ORDER BY champ_date DESC LIMIT 0,10");

while($goats=mysql_fetch_array($champer))

{
$the_game_id=$goats["champ_gid"];
$game_title=$goats["champ_gtitle"];
$game_name=$goats["champ_name"];
$game_score = $this->ipsclass->do_number_format($goats["champ_score"]);

$content .= "<tr><td class='row1' colspan='1'><a href=".$this->ipsclass->base_url."act=Arcade&do=play&gameid=".$the_game_id."> <b>$game_title</b></a></td><td class='row1' colspan='1'> <b>$game_name</b></td> <td class='row1' colspan='1'> <b>$game_score</b></td></tr>";
}
echo $content;
?>


#2 kostassakel

    Newbie

  • Members
  • Pip
  • 8 posts
  • Gender:Male
  • Location:Athens

Posted 19 November 2006 - 08:29 AM

Use this code:

<tr><th width="50%" nowrap="nowrap">Game Name</th><th width="30%" nowrap="nowrap">Champ</th><th width="20%" nowrap="nowrap">New Score</th></tr>
<?
$champer = mysql_query("SELECT c.*, g.gcat, cat.password FROM ibf_games_champs AS c, ibf_games_list AS g, ibf_games_cats AS cat WHERE c.champ_gid=g.gid AND g.gcat=cat.c_id AND trim(password)='' ORDER BY champ_date DESC LIMIT 0,10");

while($goats=mysql_fetch_array($champer))

{
$the_game_id=$goats["champ_gid"];
$game_title=$goats["champ_gtitle"];
$game_name=$goats["champ_name"];
$game_score = $this->ipsclass->do_number_format($goats["champ_score"]);

$content .= "<tr><td class='row1' colspan='1'><a href=".$this->ipsclass->base_url."autocom=arcade&code=play&g=".$the_game_id."> <b>$game_title</b></a></td><td class='row1' colspan='1'> <b>$game_name</b></td> <td class='row1' colspan='1'> <b>$game_score</b></td></tr>";
}
echo $content;
?>


It is supposed to work....For me,it seems to be working but I get this error....

IPB WARNING [2] mysql_fetch_array(): supplied argument is not a valid MySQL result resource (Line: 5 of /sources/action_public/uportal.php(1567) : eval()'d code)





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users