Fatal error: Call to a member function Active() on a non-object
-
moorezilla
Fatal error: Call to a member function Active() on a non-object
I'm running 1.0beta6 on a linux vhost, php 4.4.4, mysql 4.1.21, apache 1.3.37.
Yesterday I got the following error:
Fatal error: Call to a member function Active() on a non-object in /home/apollopr/public_html/skoogle/cpsscience/cms/plugins/function.cms_selflink.php on line 262
I blew away the database and all of the cmsms files, reinstalled everything, and it worked for a bit. Then I went to edit a page, the process timed out (blank page) and I got this error again:
Fatal error: Call to a member function Active() on a non-object in /home/apollopr/public_html/skoogle/cpsscience/cms/plugins/function.cms_selflink.php on line 262
Any ideas? I don't have any plugins installed that aren't shipped with the base package. My hosting company has seemed slow lately. Could this be a problem with something timing out and frying data?
Thanks,
am
Yesterday I got the following error:
Fatal error: Call to a member function Active() on a non-object in /home/apollopr/public_html/skoogle/cpsscience/cms/plugins/function.cms_selflink.php on line 262
I blew away the database and all of the cmsms files, reinstalled everything, and it worked for a bit. Then I went to edit a page, the process timed out (blank page) and I got this error again:
Fatal error: Call to a member function Active() on a non-object in /home/apollopr/public_html/skoogle/cpsscience/cms/plugins/function.cms_selflink.php on line 262
Any ideas? I don't have any plugins installed that aren't shipped with the base package. My hosting company has seemed slow lately. Could this be a problem with something timing out and frying data?
Thanks,
am
-
calguy1000
- Support Guru

- Posts: 8169
- Joined: Tue Oct 19, 2004 6:44 pm
Re: Fatal error: Call to a member function Active() on a non-object
on about line 260, try changing
to
and see if that helps..... well, it shouldn't do any harm anyways.
Code: Select all
if( isset($content) )Code: Select all
if( isset($content) && $content != NULL )Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
-
moorezilla
Re: Fatal error: Call to a member function Active() on a non-object
Thanks very much for the reply, Calguy.
I have made the change and so far it's working swimmingly.
Should this change be rolled into the 1.0 release, or is this more of a "your hosting company sucks" workaround? I read through the forum before I posted and, though there are several references to similar errors, I couldn't figure out if the error is caused by a low php memory limit, a faulty module, an error in the javascript controlling the expand/contract menu of pages, the limitations of mysql, or some other unidentified issue.
I'd really like to get to the bottom of it, so that I can find a hosting environment (if that's the cause) that will comfortably run CMSMS. Actually, it would be great to create a list of ISP's that offer good environments for CMSMS, and I'll gladly add to this as I find them. If anyone knows of a good ISP for CMSMS implementations (I'm currently at site5.com) and wants to share, please do.
When CMSMS installs on my current vhost, it does fire a "yellow ball" warning in the php memory column, so I was immediately suspicious of that as a possible cause. Also... the error is always, in my case, preceded by a blank page which follows what appears to be an incompleted call to the database.
I have made the change and so far it's working swimmingly.
Should this change be rolled into the 1.0 release, or is this more of a "your hosting company sucks" workaround? I read through the forum before I posted and, though there are several references to similar errors, I couldn't figure out if the error is caused by a low php memory limit, a faulty module, an error in the javascript controlling the expand/contract menu of pages, the limitations of mysql, or some other unidentified issue.
I'd really like to get to the bottom of it, so that I can find a hosting environment (if that's the cause) that will comfortably run CMSMS. Actually, it would be great to create a list of ISP's that offer good environments for CMSMS, and I'll gladly add to this as I find them. If anyone knows of a good ISP for CMSMS implementations (I'm currently at site5.com) and wants to share, please do.
When CMSMS installs on my current vhost, it does fire a "yellow ball" warning in the php memory column, so I was immediately suspicious of that as a possible cause. Also... the error is always, in my case, preceded by a blank page which follows what appears to be an incompleted call to the database.
-
calguy1000
- Support Guru

- Posts: 8169
- Joined: Tue Oct 19, 2004 6:44 pm
Re: Fatal error: Call to a member function Active() on a non-object
You're in a much better spot than some, as you're running a vhost, and if necesary, you can configure php and apache, as needed and install whatever funky little tools you need.
If you are indeed running a vhost (have a root password and all that nice stuff) then you shouldn't need to change hosts.... just tweak your php settings, etc.
although I thinkt he Active() thing is just a bug. I think that change should go into svn. it's safe.
If you are indeed running a vhost (have a root password and all that nice stuff) then you shouldn't need to change hosts.... just tweak your php settings, etc.
although I thinkt he Active() thing is just a bug. I think that change should go into svn. it's safe.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
-
Scott
Re: Fatal error: Call to a member function Active() on a non-object
Hi guys, I just go this error on version 1 stable.
It is to do with, at least in my case, deleating an entire catagorie, with subpages, from the pages menu.
It is to do with, at least in my case, deleating an entire catagorie, with subpages, from the pages menu.
Last edited by Guest on Thu Sep 14, 2006 9:24 am, edited 1 time in total.
-
moorezilla
Re: Fatal error: Call to a member function Active() on a non-object
Yep... this is very odd. I could regularly recreate the error on the last beta, but I can't seem to recreate it in 1.0 or 1.0.1. This bug obviously appears to still be there if you get the error, but it seems very quirky and doesn't show up in a predictable manner for me. Drat. I don't know if this has to do with the old javascript error that showed up with menu management, or if this has to do with the bug addressed by Calguy's fix. Calguy's fix worked on the last beta for me, but I have not looked to see if that change made it into 1.0 (I'll try to check later today), and I'm not sure if that is all we need to do in order to prevent this error in the future.
If anyone has any ideas on this, I'm/we're very interested.
Hang in there, Scott. The CMSMS guys are solid and will get to the bottom of this. This project is very active and well-run.
If anyone has any ideas on this, I'm/we're very interested.
Hang in there, Scott. The CMSMS guys are solid and will get to the bottom of this. This project is very active and well-run.
-
Scott
Re: Fatal error: Call to a member function Active() on a non-object
Hiya, I was using 1.0 not 1.0.1. In this version the changes above have not been implemented yet, I have implemented them now and it seems to solve the problem.
This issue seems to be coming from the listing of pages from the database.
If you have the following pages:
1 -Home
2 -Test1
2.1- Test1.1
3 - Test2
When you delete page 2 I assumed it would automatically remove page 2.1 and rename page 3 to page 2 in the database. This does not appear to be the case, hence the check above allows the system to ignore the fact that page 2 does not exist and still generate the menu.
Surely, it would make sense to renumber the pages if you delete or move them; otherwise, things seem to get confused!
This issue seems to be coming from the listing of pages from the database.
If you have the following pages:
1 -Home
2 -Test1
2.1- Test1.1
3 - Test2
When you delete page 2 I assumed it would automatically remove page 2.1 and rename page 3 to page 2 in the database. This does not appear to be the case, hence the check above allows the system to ignore the fact that page 2 does not exist and still generate the menu.
Surely, it would make sense to renumber the pages if you delete or move them; otherwise, things seem to get confused!
-
Scott
Re: Fatal error: Call to a member function Active() on a non-object
ok, found another problem, I can not add new pages anymore.
I did a clean default install, and the made the change above. I then deleated all the default content by deleting the parent items. This removes them from the pages view.
I then went to add some new content. I tried adding a page with no parent and it does not show up in the pages view or in the menu on the site. SO I tried adding it as a child page, and low and behold! all the old pages are still listed as potential parents (including the new page that Ijust tried to create!)
Any ideas?
I did a clean default install, and the made the change above. I then deleated all the default content by deleting the parent items. This removes them from the pages view.
I then went to add some new content. I tried adding a page with no parent and it does not show up in the pages view or in the menu on the site. SO I tried adding it as a child page, and low and behold! all the old pages are still listed as potential parents (including the new page that Ijust tried to create!)
Any ideas?
-
Scott
Re: Fatal error: Call to a member function Active() on a non-object
Quick addon, if I go to reorder pages all the pages still showup there as well, but there is no way to reorder them!
Image 1 is of adding a page and the parents
Image 2 shows that none of those pages exist, in theory!
Image 3 shows reordering the pages.
[gelöscht durch Administrator]
Image 1 is of adding a page and the parents
Image 2 shows that none of those pages exist, in theory!
Image 3 shows reordering the pages.
[gelöscht durch Administrator]
Last edited by Guest on Thu Sep 14, 2006 1:14 pm, edited 1 time in total.
-
Scott
Re: Fatal error: Call to a member function Active() on a non-object
Well I just had a look in the database, it appears that the content is n ot being removed recursively which screws everything up.
[gelöscht durch Administrator]
[gelöscht durch Administrator]
-
stef70
Re: Fatal error: Call to a member function Active() on a non-object
I just hit a similar problem today with 1.0beta6. I was editing and things started going strange after trying to reorder two pages.
I can still browse most of the pages but some of the same kind of errors mentionnd above.
I can still use the admin panel but it freezes when I try to submit a change.
I also noticed in PhpMyAdmin that the content numbering is incoherent (like the two entries with 0002.0002 in the previous screenshot). I tried to fix it without luck.
I can only do 3 parallel SQL accesses and I have the strong feeling that this is not enough to run a SQL based cms.
That's unfortunate because CMSMS was really nice
I can still browse most of the pages but some of the same kind of errors mentionnd above.
I can still use the admin panel but it freezes when I try to submit a change.
I also noticed in PhpMyAdmin that the content numbering is incoherent (like the two entries with 0002.0002 in the previous screenshot). I tried to fix it without luck.
I can only do 3 parallel SQL accesses and I have the strong feeling that this is not enough to run a SQL based cms.
That's unfortunate because CMSMS was really nice
-
moorezilla
Re: Fatal error: Call to a member function Active() on a non-object
I was able to duplicate this error in 1.0.1 by adding a page with children and then attempting to delete the parent page without deleting the children. On my end, the admin area churned, apparently deleted both the parent page and its children, and then the regular site shot up the following error:
Fatal error: Call to a member function Active() on a non-object in /home/apollopr/public_html/skoogle/cpsscience/cms/plugins/function.cms_selflink.php on line 262
From my tests, it looks like you can avoid this error by carefully deleting all children pages before attempting to delete parents, but this definitely seems like a bug that needs to be fixed.
Calguy's fix (see above post) seems to work as a quick fix, but I'm not sure if the database information needs attention. At the least, we need to get Calguy's fix into the next release if possible.
Fatal error: Call to a member function Active() on a non-object in /home/apollopr/public_html/skoogle/cpsscience/cms/plugins/function.cms_selflink.php on line 262
From my tests, it looks like you can avoid this error by carefully deleting all children pages before attempting to delete parents, but this definitely seems like a bug that needs to be fixed.
Calguy's fix (see above post) seems to work as a quick fix, but I'm not sure if the database information needs attention. At the least, we need to get Calguy's fix into the next release if possible.
Last edited by moorezilla on Thu Sep 14, 2006 6:36 pm, edited 1 time in total.
Re: Fatal error: Call to a member function Active() on a non-object
Sounds like the recursive delete needs more work.... *sigh*
I'll look into it for 1.0.2.
I'll look into it for 1.0.2.
-
moorezilla
Re: Fatal error: Call to a member function Active() on a non-object
Thanks, Ted!
Don't let the bugs get you down; I love CMSMS. It's sooooo close!
This is a GREAT open source project!
Don't let the bugs get you down; I love CMSMS. It's sooooo close!
This is a GREAT open source project!
-
Scott
Re: Fatal error: Call to a member function Active() on a non-object
I will second that! This is a really good project, the danger here is that for anyone (me!) who wants to use cmsms in a production environment. You can not afford to risk data corruption without at least having backup as a regular feature of the control panel so that you can take weekly backups of your data.moorezilla wrote: Thanks, Ted!
Don't let the bugs get you down; I love CMSMS. It's sooooo close!
This is a GREAT open source project!

