close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

The Cart is Empty

Thread began 9/06/2009 2:30 am by anitah355532 | Last modified 10/09/2009 9:37 am by Jason Byrnes | 5331 views | 10 replies |

anitah355532

The Cart is Empty

The first time anyone tries to order something on my site they end up with a message telling them "The cart is empty".

The process is:

Add to Cart - Checkout
Paypal button selected
Paypal login and review

Once the Paypal site's continue button is pressed the customer is re-directed back to the Powerstore site and cart.php appears with the message "The cart is empty".

This only happens the first time someone tries to purchase something. The second time it works ok - they are redirected from Paypal to the pp_confirm.php where they can confirm the order and checkout.

I've tried inserting <?php if(!session_id()) session_start(); ?> at line 1 of the cart page.

I've tried adding session_commit(); after // WA eCart Redirect on the cart and pp_confirm pages.

Do you have any idea what else I can try to get this resolved?

www.voyagermoon.com

Sign in to reply to this post

Jason ByrnesWebAssist

The cart contents are stored in a session variable. Session variables use a cookie to track the session contents. The cookie is set based on the domain.

When a user comes to your site at:
cart

a cookie is set to track session contents, when they get redirected from paypal back to your site, they are directed to a different domain:
cart


in the WA_Globals.php, make sure to set the $WAGLOBAL_Root_URL variable to www.voyagermoon.com/

Sign in to reply to this post

anitah355532

Brilliant ! All sorted :-)

Thanks for figuring out where I went wrong.

Sign in to reply to this post

anitah355532

Spoke too soon......

I changed the WA_Globals file to read: $WAGLOBAL_Root_URL = "http://www.voyagermoon.com/";

The result is that someone purchasing a product on the .com domain has no problems. Paypal redirects them back to the confirm page as it should.

But - when someone purchases a product on the .com.au domain they end up back at .com with the message "the cart is empty".

Sign in to reply to this post

Jason ByrnesWebAssist

You will need to use a script to check the domain they are entering your site from and force them over to the correct one. There are many different ways of doing this depending on your server type. it can be done using htaccess or a number of other ways.

Sign in to reply to this post

anitah355532

Thanks Jason, the domain hosting company's control panel had a simple way of setting the redirect up. The cart works fine now.

Sign in to reply to this post

Jason ByrnesWebAssist

Excellent, glad to hear it.

Sign in to reply to this post

morc.mzw383871

Click "checkout" leads to "The cart is empty" only for the first time

Hi,

Every time a new customer click on "checkout", the next page says "The cart is empty"m i.e. does not direct the client to the "payment" page.

However, if the customer remain on the same browser, he does not experience this issue anymore (i.e. if he adds to cart and clicks "checkout" again - he is directed to the payment page the 2nd time). However, if he closes this old browser and opens a new one, this error happens again. The customer is using IE 6.0.

Please advise. Thank you.

Sign in to reply to this post

Jason ByrnesWebAssist

Please post a link to your site so I can try to recreate the problem to see what is going wrong.

Sign in to reply to this post

morc.mzw383871

The Cart is Empty (1st time)

Hi Jason,

Please attempt to make a purchase@ Products_Detail.php?ProductID=7

Browser IE 6.0 and Ffox 2.0.0 show the same error/issue. Have not tried other browser.

Thanks.

Sign in to reply to this post
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...