TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

May 01, 2024, 09:24:17 PM

Login with username, password and session length
Members
  • Total Members: 3,885
  • Latest: Growner
Stats
  • Total Posts: 195,175
  • Total Topics: 21,220
  • Online today: 177
  • Online ever: 3,540 (September 03, 2022, 01:38:54 AM)
Users Online

Arcade Games Block

Started by alhaudhie, February 07, 2007, 05:51:05 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

alhaudhie

can u help me...

see in halaqah.net

i have install

require('./Settings.php');

$top = highscore();
//echo "<pre>".print_r($top,true)."</pre>";

foreach($top as $temp){

echo"<table align=\"center\" width=\"100%\"><tr><td align=\"center\" class=\"smalltext\">{$temp['realName']}</td></tr>";
echo "<tr><td align=\"center\" class=\"smalltext\">{$temp['name']} - {$temp['score']}</td></tr><tr><td width=\"100%\"><hr></td></tr></table>";
}
function highscore($count = 5, $game = "", $cutoff = 0)
{
global $link,$db_prefix,$boarddir,$boardurl;

if($game == "")
$query = "SELECT * FROM {$db_prefix}games,{$db_prefix}games_high,{$db_prefix}members WHERE {$db_prefix}games.game={$db_prefix}games_high.game AND {$db_prefix}games_high.member={$db_prefix}members.ID_MEMBER ORDER BY score DESC LIMIT 0,{$count}";
else
$query = "SELECT * FROM {$db_prefix}games,{$db_prefix}games_high,{$db_prefix}members WHERE {$db_prefix}games.game={$db_prefix}games_high.game AND {$db_prefix}games_high.member={$db_prefix}members.ID_MEMBER AND {$db_prefix}games.game='{$game}' ORDER BY score DESC LIMIT 0,{$count}";
$res = mysql_query($query) or die(mysql_error());
$top = array();
while($x = mysql_fetch_array($res))
{
$x['score'] = (string)$x['score'];
$top[] = $x;

}
return $top;
}


now i cannot do anything....
where can i delete this file in my ftp/database

JPDeni

I put your code in a bbc code "wrapper" so it was readable.

You said you "installed" it. How did you install it? Is it in a block? Is it in a separate php file? Where is it?

You saod "now I cannot do anything". What do you mean. Do you get a blank page? Do you get an error message?

From looking at your site, I'm going to guess that this is in the block that has the title "games" on the left side that says "Table 'halaqah_smf.halaqah_games' doesn't exist". If I'm right and you want to get rid of it, just go to your SMF admin and delete the block. If you ignored the repeated suggestions here and are showing the blocks while in the admin area, you'll have to access your database and fine your tp blocks table and delete the record from there. Then, go to your admin area in the TP settings and select the option to hide the blocks while in the admin area so you don't run into this problem again.

But I could be wrong and you could be talking about something completely different. If so, you'll need to explain your problem more explicitly before anyone can help you.