Page 1 of 1

PHP_Incomplete_Class - Error

PostPosted: August 29th, 2010, 6:24 am
by Adeptris
Hi,
I am new to s2Member, (about 3 hours) and was using wp-member before, so I will have to upgrade to pro to import the old subscriptions (only 4), as I cannot see another way.

I went through all the setups, and the login page comes up and I can login and out just fine, so that part is all good.

I am using a 'twenty ten' child theme with Buddy Press merged, which is now the WordPress prefered way.

It is setup as Multi Site but not a Multi Blog Farm (users cannot create blogs), I allowed the setup to merge the files.

In the Admin > Users I have the 4 members to update, I go to edit > role > change to 's2Member Level 2'

I get this error:
Catchable fatal error: Object of class __PHP_Incomplete_Class could not be converted to string in D:\mywebsite.net\MyRootFolder\wp-includes\functions.php on line 1463

In fuctions.php is the following:
The Function = add_magic_quotes($array)
The line 1463 = $array[$k] = addslashes( $v );

If I change to any of the standard roles then it works without the error, so author, editor etc: are fine.


David

Re: PHP_Incomplete_Class - Error

PostPosted: August 30th, 2010, 12:47 pm
by Jason Caldwell
Hi David. Thanks for reporting this.
I've not been able to reproduce this with BuddyPress/s2Member/Multisite.

However, I did find this article:
http://www.crainbandy.com/programming/p ... -_sessions

Do you have any plugins that require sessions?
If so, is session.auto_start on in your php.ini file. If so, try turning that off.
Given the harmless section of code that is your symptom, it sounds like a server configuration issue to me. That being said, I've never encountered this myself, so please let me know if you narrow this down. I'd love to hear about it.

Re: PHP_Incomplete_Class - Error

PostPosted: September 4th, 2010, 8:00 am
by Adeptris
Hi Jason,
I tested it some more on new users and it only happens to the four old wp_member users, I will need to investigate more!

David

Re: PHP_Incomplete_Class - Error

PostPosted: September 7th, 2010, 8:11 pm
by Jason Caldwell
Thanks for reporting back David.
~ Much appreciated.

So it sounds like it's possible that the wp_capabilities field in the usermeta table might have become corrupted for specific Users? WordPress® stores an array of Roles/Capabilities into that key ( serialized ). So I suppose it is possible that the PHP_Incomplete_Class error is being triggered by a corrupt serialized array; where there might have been a particular plugin installed at some point that stored data directly into that field, possibly even as an object, instead of as an array.