The Support Forums will be in read-only mode for a scheduled maintenance window on 01 September 2016 14:00 UTC - 20:00 UTC. More information.

TheCartPress eCommerce Shopping Cart
Events Manager incompatibility? (4 posts)

  1. theobsidian
    Posted 4 years ago #

    I'm setting up an e-commerce section on a charity foundation website and it looks like there's an incompatibility between events manager and cartpress plugin, products pages shows this error message (I tried to deactivate events manager and cartpress works fine):

    Fatal error: TheCartPress::wp_head_last_visited() [thecartpress.wp-head-last-visited]: The script tried to execute a method or access a property of an incomplete object. Please ensure that the class definition "ShoppingCart" of the object you are trying to operate on was loaded _before_ unserialize() gets called or provide a __autoload() function to load the class definition in C:\xampp\htdocs\mkmrf\wp-content\plugins\thecartpress\TheCartPress.class.php on line 171

    Does anybody has experienced this problem or it's just me?


  2. jeroenkroon
    Posted 4 years ago #

    Having the exact same problem, with the same plugins. It looks like the Events Manager is starting a session before the cartpress is fully loaded. I'm looking at the different codes right now but i can't find event manager starting a session anywhere. Still searching though.

    This issue is also posted on the cartpress support fora.

  3. jeroenkroon
    Posted 4 years ago #

    Ok, just comment out line 11 in the file "em-notices.php" (found in the classes subdir of your events manager plugin). It is the line that says: session_start();

    Change to: //session_start();

    Not sure if this breaks event manager but after running some quick tests it seems to work fine for both. If it does break the plugin, just remove the // and your back to square 1!

    With my little knowledge, no it seems that cartpress starts the session so it get's a change of fully loading all classes. If there is a better solution, i would be glad to know!

  4. theobsidian
    Posted 4 years ago #

    Thank you, I tried your solution and it seems to work; I'm still testing but it looks that nothing else is broken...
    I'll try to contact events manager plugin development, maybe they can do something in their next version..

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic