1
Dorsey
Php bloc not working
  • 2010/7/26 10:54

  • Dorsey

  • Just popping in

  • Posts: 1

  • Since: 2010/7/26


Hi all,

First i'm sorry for my english but i'm a french user.
I've try to solved my problem on xoops french but the problème is still here, maybe, I'going to have more chance with you.

I use xoops 2.4.4 and when I try tu put a personnalised php bloc, nothing appear and the content of my xoops desepear.

my code is :
$db = mysql_connect('localhost', 'root', ''); 

mysql_select_db('BDD_Name',$db); 

$req = mysql_query('SELECT * FROM bdd_users'); 
$res = mysql_num_rows($req); 

echo 
'Il y a '.$res.' enregistrement(s) dans la table.'; 
mysql_close($db);

On my debug I've :
Avertissement(s): mysql_query(): 41 is not a valid MySQL-Link resource dans le fichier /class/database/mysqldatabase.php - ligne 260
and
Avertissement(s): Smarty error: unable to read resource: "db:newbb_index.html" dans le fichier /class/smarty/Smarty.class.php - ligne 1093

Maybe it's a way.

Thanks so much all