hi!
bin nun endlich zum ausprobieren gekommen!
leider bekomme ich einen Fehlercode:
MySQL Error:
1064 : Fehler in der SQL-Syntax. Bitte die korrekte Syntax im Handbuch nachschlagen bei 'WHERE id != 1' in Zeile 1
in Query:
SELECT id, name, posts FROM ic1_user ORDER BY posts DESC LIMIT 5 WHERE id != 1
Debug backtrace:
@ mysql.php:32 -- debug_bt()
@ mysql.php:50 -- db_check_error(...)
@ topuser.php:8 -- db_query(...)
@ design.php:330 -- require_once(...)
@ design.php:252 -- design->get_boxcontent(...)
@ design.php:44 -- design->get_boxes(...)
@ self.php:68 -- design->design(...)
@ index.php:31 -- require_once(...)
Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /var/www/web456/html/ESGbeta2/include/includes/func/db/mysql.php on line 67
hier mal meine topuser.php:
<?php
//Copyright by Stefan Jungbauer
//www.zocker-eppingen.de
//V 1.1
defined ('main') or die ( 'no direct access' );
$erg = db_query("SELECT id, name, posts FROM prefix_user ORDER BY posts DESC LIMIT 5");
$i = 0;
echo '<table width="100%">';
while ($row = db_fetch_object($erg) ) {
$i++;
echo '<tr><td width="70%">'.$i.'. <a href="index.php?user-details-'.$row->id.'">'.$row->name.'</a></td><td>('.$row->posts.')</td></tr>';
}
echo '</table>';
?>
kann noch mal einer drüberschauen??