Easy Guide How To Empty Shopping Cart Use simpleCartjs Blogger Store Plug-ins

@ written .Sunday, July 17, 2016   

Easy Guide How To Empty Shopping Cart Use simpleCartjs Blogger Store Plug-ins
March/April 2016 GiveAway Ended- 25 lucky winners have been announced & contacted. Congratulations! Prizes worth rm2500.00 have been distributed.
Subscribe our Blogger theme tutorial channel & more freebies awaits https://youtu.be/UUh_IEFx4Ac. Thanks for the support!
Update 18th July 2016

All current BlogrCart Blogger store themes with shopping cart have already pre-installed these functions, which included sample pages for quick template installs. View our Blogger theme gallery for instant downloads here at http://sellfy.com/irsah

Original Article published 1st November 2015

In this tutorial we will show you how to automatically empty the shopping cart after users successfully sent in their order via Paypal or by email notification. At earlier BlogrCart Blogger store templates releases, users are required to include the dedicated helper function to empty the shopping cart.

pre-made etsy.com blogger shopping template free download easy install

Beginning BlogrCart Mukabuku Elite blogger template, the replacement theme for Blogrcart MukaBuku found here http://blogrcart-mukabuku-elite.blogspot.com , the functions comes built in with the theme/template set-ups.


Manually Add Empty Shopping Cart Helper


Since that for every successful submitted orders either by Paypal or email notifier, users are redirected to your Success order page. This give plenty of room for you to customize additional instructions to your users.

While users are headed here, this would be the best spot for you to include the helper functions to empty the shopping cart since that the orders have been sent/notified earlier.

In this case, open up your Success page and click HTML view. Add below code to empty the shopping cart stored at your users web browsers.

<script>
  $(document).one('ready', function () {
    for(simpleCart_items in localStorage) {
      delete localStorage[simpleCart_items];
    };
  });
</script>

What this function do is to remove all shopping cart data saved at users browsers once he or she visits this Success page.

Update November

Since that some of BlogrCart themes adds in the jQuery library (extension for javascript) at footer for best page web practices, you can modify the code above to activate the functions using javascript only like so...

<script>
  window.onload = function(){
    for(simpleCart_items in localStorage) {
      delete localStorage[simpleCart_items];
    };
  };
</script>

Add Empty Shopping Tag Helper


For current BlogrCart themes, users only required to include the special tag to remove the shopping cart data when users visits the Success page.

At your Success page click HTML and add below tag, anywhere at the bottom of your texts:-

<div class="empty-shopping-cart"></div>

Click Save & test that the shopping cart will be emptied once you have visited this page.

There you go. More ways to enhance your Blogger powered e-commerce web store & handle more gracefully your users experience shopping at your store.

If you find this tutorial useful, Tweet us & add us to your social network. More Blogger themes can be downloaded here at our template gallery http://sellfy.com/irsah

You can take part too!
Join our sponsors!

This website or its third party tools use cookies, which are necessary to its functioning and required to achieve the purposes illustrated in the cookie policy. By tapping on "I accept" you agree to the use of cookies.