close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

ecart cookie name

Thread began 12/21/2011 8:17 am by dave315749 | Last modified 3/12/2012 9:55 am by toms016390756 | 2513 views | 10 replies |

dave315749

ecart cookie name

Cart items are storied in cookie,

what is the name of the cookie so i can clear it after a successful checkout ?

Sign in to reply to this post

Jason ByrnesWebAssist

use the eCart Clear Cart server behavior on the checkout success page to clear the cart.

On the server behaviors panel (Window -> Server Behaviors), click the plus button and select eCart -> Cart Display -> Clear Cart. Set the trigger to before page load.

Sign in to reply to this post

dave315749

Then i would move the code to the bottom of the page right? since then it wouldnt show the items on the checkout success page if it was to load above the header ?

Sign in to reply to this post

Jason ByrnesWebAssist

yes, that is correct, the clear cart code would need to be moved to the bottom of the page.

Sign in to reply to this post

dionysus224892

What is the Cookie name though?

I am curious if it's being set and I would like to know the name so I can check in my browser.

Sign in to reply to this post

Jason ByrnesWebAssist

the name will be "<cartName>_Items" where <cartName> is the name of your cart object

Sign in to reply to this post

dionysus224892

Thanks for that! But there's still a hitch unfortunately. I notice that even though I set my cookie to expire after 99999 days, when I look in the browser, it says Expires when I quit my browser.

Is there a way to ensure the cookie lasts as long as I would like it to?

Sign in to reply to this post

Jason ByrnesWebAssist

can you send a link where i can see the problem and a copy of the eCart object file from the WA_eCart folder.

Sign in to reply to this post

dionysus224892

Sorry for the delay, Jason. And thanks for your constant presence in these forums. I appreciate your help!

Here is the code from the ecart :

function SetCookieInfo($theCookieString) {
$numDays = 99999;
$theDomain = "";
$thePath = "";
$cookSec = false;
if ($numDays == "") $numDays="0";
$theDate = strtotime("+".$numDays." Days");
setcookie($this->CartName."_Items", $theCookieString, $theDate, $thePath, $theDomain, $cookSec);
}


I'd like to know why it isn't working as it seems it should, however, I've changed the way my site works. I'm using the cart as a wish list, however, on logout, I save the cart to a database and on login, I create a new cookie as ecart would make it, therefore allowing ecart to access it during active use.

So it's not urgent but I'm still curious why it doesn't work.

However, I have another problem that I hope you might answer. I am saving books (title, author and description) to the wish list and when saving to the cookie, for some reason when I add to cart, any apostrophes effectively truncate what's being added to the card. Even though I manually added mysql_real_escape_string, somehow, it's still not working. So when I want to see the description displayed on the cart page, wherever there is an apostrophe—that's the end of the entry.

Any ideas?

Sign in to reply to this post

Jason ByrnesWebAssist

I have created a support ticket so we can look into this issue further.

To view and edit your support ticket, please log into your support history:
supporthistory.php

If anyone else is experiencing this same issue, please append to this thread.

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...