Support

Home Forums Event Espresso Premium Add to cart not working

Add to cart not working

Posted: August 16, 2013 at 4:02 pm


Bogdan Vrusias

August 16, 2013 at 4:02 pm

I am trying for 2 days now to figure out why the links to add an event to cart stopped working, but I cannot solve it. I tried:
1. disabling other plugins
2. renaming the templates folder
3. checking for any library conflicts
4. different browsers
5. restarting apache
6. removing EE widgets from the sidebar

… but no luck. Clicking on add to cart link show as it does work, but when I go to the cart is empty!

Could someone please check this url (http://www.technotomy.com/training/course-registration/) in case you can think of something?

There is one more strange thing… although I have captcha enabled, it does not show up. Can that be related or is that a second problem?


Bogdan Vrusias

August 16, 2013 at 4:05 pm

Just to add that I have the latest version of EE (v3.1.34.1.P) and it’s plugins and same for WP (v3.6).


Josh

  • Support Staff

August 16, 2013 at 4:21 pm

Hi there,

The captcha is working, but you will need to log out of the site before it will show up.

The cart is behaving like it’s not able to save sessions. I’ve seen this happen before where the session save path directive was changed on the server side of things (or vice versa, the server was migrated and the path wasn’t update), or the file permissions were changed for the directory where the sessions get saved:

http://www.php.net/manual/en/session.configuration.php#ini.session.save-path


Bogdan Vrusias

August 16, 2013 at 4:44 pm

Hi Josh,

Thanks for the prompt reply!

I checked /var/lib/php5 and I can see a session file created when I try to add to the cart:
espresso_session|a:4:{s:2:”id”;s:56:”7e7baeda736913b48cd8d31e3d32e253-520e7f85a6adc4.42869534″;s:17:”events_in_session”;s:0:””;s:11:”grand_total”;N;s:15:”volume_discount”;i:0;}

So the system can access the directory and save the session information I presume.

Could it be something else?


Bogdan Vrusias

August 16, 2013 at 4:51 pm

Actually… there are two session files created:

1. sess_hs9d5ouhv1pvnsmv5nsqu1rq05
espresso_session|a:3:{s:2:”id”;s:50:”hs9d5ouhv1pvnsmv5nsqu1rq05-520eac74d72e37.40199220″;s:17:”events_in_session”;a:1:{i:32;a:7:{s:2:”id”;s:2:”32″;s:10:”event_name”;s:37:”Web Application Development with Java”;s:18:”attendee_quantitiy”;i:1;s:13:”start_time_id”;s:0:””;s:8:”price_id”;a:0:{}s:4:”cost”;d:0;s:15:”event_attendees”;a:0:{}}}s:11:”grand_total”;s:0:””;}

2. sess_7e7baeda736913b48cd8d31e3d32e253
espresso_session|a:4:{s:2:”id”;s:56:”7e7baeda736913b48cd8d31e3d32e253-520e7f85a6adc4.42869534″;s:17:”events_in_session”;s:0:””;s:11:”grand_total”;N;s:15:”volume_discount”;i:0;}


Josh

  • Support Staff

August 16, 2013 at 5:30 pm

That narrows things down a bit. Do the session variables stay when you refresh the page after you add an event to the cart? The reason I ask is I’m seeing the “View Cart” link go back to “Add to Cart” after the page refreshes.

It almost seems like there’s some code running when the page loads that’s clearing the session.


Bogdan Vrusias

August 16, 2013 at 5:46 pm

When I add an item to the cart both files are created with the data (as above)… when I refresh the page one of the files gets created (the second one, as in the example above)… but the first file (the one created when clicking on the add to cart link) remains there unchanged.

Everything used to work a few days ago 🙁


Josh

  • Support Staff

August 19, 2013 at 7:56 am

Can you recall, or check into, anything has changed on the server around the time this started not working? Examples are: server upgrades, new plugins installed, updated plugins, changes to the page that has the [ESPRESSO_EVENTS] shortcode on it?

The support post ‘Add to cart not working’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso