• hi guys,

    im having problem with my (Facebook Connect WordPress Plugin). I upgraded my wordpress to 2.9 then I cannot longger activate the Facebook Connect WordPress Plugin..

    heres the error.. Facebook Connector

    Plugin could not be activated because it triggered a fatal error.

    Fatal error: Cannot redeclare json_encode() (previously declared in /blogs/wp-includes/compat.php:128) in /blogs/wp-content/plugins/fbconnect/fbConfig_php4.php on line 143

Viewing 2 replies - 1 through 2 (of 2 total)
  • Same problem–please let me know if you figure out a solution. I’ll definitely post here if I find anything.

    Got a fix if you need it–you’ll need to have direct file access to your blog on your server though. In your blog directory, go to:

    /wp-content/plugins/fbconnect/

    then open the file called fbConfig_php4.php. Go down to the very end (lines 143-147). Should look like this:

    function json_encode($data){
    	require_once 'facebook-client4/classes/JSON.php';
    	$json = new Services_JSON();
    	return $json->encode($data);
    }

    We’re just going to comment out this section of code so it never runs–with the wordpress 2.9 update, this section is obsolete. So, add two backslashes to the start of every line. Should look like this:

    //function json_encode($data){
    //	require_once 'facebook-client4/classes/JSON.php';
    //	$json = new Services_JSON();
    //	return $json->encode($data);
    //}

    That’s it! Things should be back up and running.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Facebook Connect WordPress Plugin WP 2.9’ is closed to new replies.