You are missing our premiere tool bar navigation system! Register and use it for FREE!

NukeCops  
•  Home •  Downloads •  Gallery •  Your Account •  Forums • 
Readme First
- Readme First! -

Read and follow the rules, otherwise your posts will be closed
Modules
· Home
· FAQ
· Buy a Theme
· Advertising
· AvantGo
· Bookmarks
· Columbia
· Community
· Donations
· Downloads
· Feedback
· Forums
· PHP-Nuke HOWTO
· Private Messages
· Search
· Statistics
· Stories Archive
· Submit News
· Surveys
· Theme Gallery
· Top
· Topics
· Your Account
Who's Online
There are currently, 47 guest(s) and 1 member(s) that are online.

You are Anonymous user. You can register for free by clicking here
Nuke Cops :: View topic - admin secure is screwing thing up!! [ ]
 Forum FAQ  •  Search  •   •  Memberlist  •  Usergroups   •  Register  •  Profile •    •  Log in to check your private messages  •  Log in

 
This forum is locked: you cannot post, reply to, or edit topics.  This topic is locked: you cannot edit posts or make replies.printer-friendly view
View previous topic Log in to check your private messages View next topic
Author Message
yearone
Nuke Cadet
Nuke Cadet


Joined: Sep 01, 2004
Posts: 2


PostPosted: Wed Sep 01, 2004 11:07 am Reply with quoteBack to top

Quote:
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
Find all posts by yearoneView user's profileSend private messageSend e-mailVisit poster's websiteAIM AddressMSN Messenger
madman
Support Mod
Support Mod


Joined: Feb 15, 2004
Posts: 806


PostPosted: Wed Sep 01, 2004 11:34 am Reply with quoteBack to top

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 Image
Find all posts by madmanView user's profileSend private messageVisit poster's websiteYahoo MessengerMSN Messenger
Evaders99
Site Admin
Site Admin


Joined: Aug 17, 2003
Posts: 12397


PostPosted: Wed Sep 01, 2004 12:23 pm Reply with quoteBack to top

Isn't it always somehow the script's fault? Never the users fault, no... Smile

Looks like your database has been hosed. Or you did not install X,Y,Z correctly...

_________________
Helping those that help themselves
Read FIRST or DIE!

"Fighting is terrible, but not as terrible as losing the will to fight."
Star Wars Rebellion Network - Need Help? Evaders Squadron Coding
Find all posts by Evaders99View user's profileSend private messageVisit poster's websiteAIM Address
madman
Support Mod
Support Mod


Joined: Feb 15, 2004
Posts: 806


PostPosted: Wed Sep 01, 2004 12:46 pm Reply with quoteBack to top

Evaders99 wrote:
Isn't it always somehow the script's fault? Never the users fault, no... Smile

Smile 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:
Code:
if ($result = $db->sql_query("select a1, a2 from table")) {
  list($a1, $a2) = $db->sql_fetchrow($result);
  $db->sql_freeresult($result);
  unset($result);
} else {
  $a1 = $a2 = null;
}

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 Image
Find all posts by madmanView user's profileSend private messageVisit poster's websiteYahoo MessengerMSN Messenger
Evaders99
Site Admin
Site Admin


Joined: Aug 17, 2003
Posts: 12397


PostPosted: Wed Sep 01, 2004 6:59 pm Reply with quoteBack to top

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.

_________________
Helping those that help themselves
Read FIRST or DIE!

"Fighting is terrible, but not as terrible as losing the will to fight."
Star Wars Rebellion Network - Need Help? Evaders Squadron Coding
Find all posts by Evaders99View user's profileSend private messageVisit poster's websiteAIM Address
madman
Support Mod
Support Mod


Joined: Feb 15, 2004
Posts: 806


PostPosted: Thu Sep 02, 2004 8:57 am Reply with quoteBack to top

Evaders99 wrote:
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. Smile
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.

_________________
I'm Image
Find all posts by madmanView user's profileSend private messageVisit poster's websiteYahoo MessengerMSN Messenger
Display posts from previous:      
This forum is locked: you cannot post, reply to, or edit topics.  This topic is locked: you cannot edit posts or make replies.printer-friendly view
View previous topic Log in to check your private messages View next topic
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



Powered by phpBB © 2001, 2005 phpBB Group

Ported by Nuke Cops © 2003 www.nukecops.com
:: FI Theme :: PHP-Nuke theme by coldblooded (www.nukemods.com) ::
Powered by · TOGETHER TEAM srl ITALY http://www.togetherteam.it · DONDELEO E-COMMERCE http://www.DonDeLeo.com
Web site engine's code is Copyright © 2002 by PHP-Nuke. All Rights Reserved. PHP-Nuke is Free Software released under the GNU/GPL license.
Page Generation: 0.216 Seconds - 251 pages served in past 5 minutes. Nuke Cops Founded by Paul Laudanski (Zhen-Xjell)
:: FI Theme :: PHP-Nuke theme by coldblooded (www.nukemods.com) ::