Google

NukeCoder


View next topic
View previous topic
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.
Author Message
Mark
Guest






PostPosted: Tue Dec 28, 2004 4:00 pm
Reply with quote

Fatal error: Call to a member function on a non-object in /var/www/html/footer.php on line 62


I get this when I access the Journal module. This is the line:

$result1 = $db->sql_query("SELECT autostate, autolast, autoinc F ROM ".$prefix."_advbackup where id='1'");
 
gotcha
Site Admin
Site Admin



Joined: Oct 25, 2004
Posts: 921

PostPosted: Tue Dec 28, 2004 4:51 pm
Reply with quote

This is a problem with the journal module. To fix it i just opened up functions.php inside the modules/Journal folder and changed this:

Code:
function journalfoot() {
    include("footer.php");
}


to this:
Code:
function journalfoot() {
   global $prefix, $db;
    include("footer.php");
}


you are just adding the "global $prefix, $db;" part.
That should do it. Let me know if you have more problems!

Also make sure there is no space in the word FROM in the line you posted above.
 
View user's profile Send private message Visit poster's website
Mark
Guest






PostPosted: Thu Dec 30, 2004 6:36 am
Reply with quote

Thanks, that fixed the Journal problem but now I see that Gallery also has the same error.

Any ideas as to where the bit of code I need to add is?
 
gotcha
Site Admin
Site Admin



Joined: Oct 25, 2004
Posts: 921

PostPosted: Thu Dec 30, 2004 1:34 pm
Reply with quote

first undo the fix from above on journal.

next open up footer.php

find

Code:
//start auto backup code
   $result1 = $db->sql_query("SELECT autostate, autolast, autoinc FROM ".$prefix."_advbackup where id='1'");


change to

Code:
//start auto backup code
global $prefix, $db;
   $result1 = $db->sql_query("SELECT autostate, autolast, autoinc FROM ".$prefix."_advbackup where id='1'");


that should work in case any other modules aren't compatible
 
View user's profile Send private message Visit poster's website
Mark
Guest






PostPosted: Fri Dec 31, 2004 9:13 am
Reply with quote

Thank you, that worked very nicely.
 
Dean
Guest






PostPosted: Thu Jan 13, 2005 3:15 pm
Reply with quote

I was about to post the same problem and saw this fix, applied it and found the desired results. Thank you so very much for this script!!!!!!!
 
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.

View next topic
View previous 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
You cannot attach files in this forum
You cannot download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 5 Hours
Forums ©