• For the attention of Otto but anyone who can help is welcome to answer.

    I’m trying to use you facebook plugin to auto-post new blog posts to facebook. That is the only functionality I require.

    However when the Simple Facebook Connect is enabled it seems to break single product pages within my store which uses wp e-commerce.

    I get this error when I visit a single product page:
    Fatal error: Cannot redeclare makethumburl() (previously declared in /home/serge870/public_html/wp-content/plugins/wp-e-commerce/wpsc-theme/wpsc-single_product.php:50) in /home/serge870/public_html/wp-content/plugins/wp-e-commerce/wpsc-theme/wpsc-single_product.php on line 50

    This refers to a custom function I wrote a while back which calls image thumbnails for the products. I.e. I wrote my own code to get the multi images for products rather than buy the gold cart. The function can be seen here: http://pastebin.com/ZK1V9KSv and works perfectly with the facebook plugin disabled.

    Deactivating the Simple Facebook Connect plugin solves it. Any ideas about this conflict?

Viewing 3 replies - 1 through 3 (of 3 total)
  • I have the same problem. I want to use simple connect, but it causes WP commerce plug-in not to work. Anyone know how to fix this or another Facebook integration plug in that would work.

    stonefree

    (@stonefree)

    After a couple hours or research I found a solution. Apparently the problem affects a few other plugins as well. Not sure the exact problem, but it seems to have something to do with plugins that alter the main database query. See here for a detailed discussion between Otto and another plugin developer.

    Anyways, to fix the issue with WPEC, go to sfc-base.php and look for function sfc_base_meta. This is where the problems are happening. Look for if (is_singular()) {
    global $wp_the_query;

    After this I included

    if ($wp_the_query->query_vars['pagename'] == 'store' || $wp_the_query->query_vars['post_type'] == 'wpsc-product')
                return;

    You may have to modify this a bit depending on how your store is set up and the complexity of it, but this seemed to do the trick for me. Basically, it ends the function if I’m on the “Store” page (for wpsc-products_page.php) or if I’m on a single product.

    There’s still the minor issue of the Publisher module causing a fatal error (“Fatal error: Call to a member function get() on a non-object in /wp-includes/query.php” ) when trying to Edit Page for “Store”, but that’s not something you’ll likely need, and can always disable the Publisher module if needed.

    Hope this helps!

    tejas.ampheetech

    (@tejasampheetech)

    Hello stonefree,

    Many many thanks for your help.
    Your suggestion work like a charm.

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘[plugin: Simple Facebook Connect] Breaks wp e-commerce’ is closed to new replies.