Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in /home2/yearonem/public_html/snowskate/includes/sql_layer.php on line 286
Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in /home2/yearonem/public_html/snowskate/includes/sql_layer.php on line 286
Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in /home2/yearonem/public_html/snowskate/includes/sql_layer.php on line 286
Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in /home2/yearonem/public_html/snowskate/includes/sql_layer.php on line 286
Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in /home2/yearonem/public_html/snowskate/includes/sql_layer.php on line 286
i get that at the top of my page.......every page that is!!!!!
and also protector isnt working and nither is sentinal all the same s*h*i*t!
_________________ its me nuke newbie...haha
madman Support Mod
Joined: Feb 15, 2004
Posts: 806
Posted:
Wed Sep 01, 2004 11:34 am
The warning text does not related to any of Admin Secure, Protector, or Sentinel whatsoever. Be sure your site is running properly before installing any of script programs.
_________________ I'm
Evaders99 Site Admin
Joined: Aug 17, 2003
Posts: 12397
Posted:
Wed Sep 01, 2004 12:23 pm
Isn't it always somehow the script's fault? Never the users fault, no...
Looks like your database has been hosed. Or you did not install X,Y,Z correctly...
Isn't it always somehow the script's fault? Never the users fault, no...
It could be caused by incorrect database settings, or bad coding. Take a look at the following code which I mean "bad coding":
Code:
list($a1, $a2) = $db->sql_fetchrow($db->sql_query("select a1, a2 from table"));
There's no error checking for result returned from SQL query. The code still working as expected if everything are normal (error free) but it still isn't good. If something wrong happen in db (e.g no tables of records found), then we'll get such warning message. Unfortunately, such typical "bad coding" can be found on many of PHP-Nuke standard scripts.
In contrast, the following code will always expecting errors and take necessary actions whenever it happen:
This code also keep memory usage as low as possible through free_result() method and unset() function (default PHP setting limits memory usage up to 8MB per request).
_________________ I'm
Evaders99 Site Admin
Joined: Aug 17, 2003
Posts: 12397
Posted:
Wed Sep 01, 2004 6:59 pm
My comment wasn't a criticism of the coders nor of Admin Secure. I know very well that no program is ever 100% perfect.
I meant it as a comment on those who install something and immediately say "XXX screwed my system" when, in fact, they did something wrong.
Thanxs for the code madman. I'll have to remember to take that into account.
To yearone: I hope you get your problems fixed. Post here if you figure out anything or have any more questions.
My comment wasn't a criticism of the coders nor of Admin Secure. I know very well that no program is ever 100% perfect.
It's okay for me.
I always need feedbacks and criticisms, because these are all I need to improves the programs. Things like "it's great" or "you're the best" simply will stop creativities and imaginations.
Evaders99 wrote:
I meant it as a comment on those who install something and immediately say "XXX screwed my system" when, in fact, they did something wrong.
Ok, back to topic. I saw the error was came from old db abstraction layer ($dbi var) and this could be anything. First, not all security addons support older db abstraction layer. Second, if they do then we need to set configuration settings properly.
Admin Secure basically support older abstraction layer came with original PHP-Nuke 6.0 or lower. But user have to adjust this in asconfig.php, under $db_compat variable. By default, this variable is set to support only new db abstraction layer through $db object.
Evaders99 wrote:
Thanxs for the code madman. I'll have to remember to take that into account.
Always expecting unexpected conditions (including logical and external errors) is the basic rule for any programming languages.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum