Add to Cart button add to Mini Sidebar Cart?

jcyinjcyin Member
in Help edited September 2012
I'm currently creating a site using Sitegrinder, I would like to have my Add to Cart buttons add directly to a mini shopping cart in the sidebar of my site. Currently when I click on the Add to Cart button, I am each time redirected to the Shopping Cart page which I then have to refresh back to the main page. This is quite time consuming and redundant when my visitors wish to buy multiple products.

Is there a quick and simple way for me to have each Add to Cart click directly add the product to the sidebar mini cart?

Thank You
Comments
  • fc_adamfc_adam FoxyCart Team
    @jcyin,

    If you've included the FoxyCart files in your head (as found in the Sample Code section of your stores administration) then by default the add to cart's should open inside the modal window like it does on our example links: http://www.foxycart.com/features/examples

    For adding to cart silently (like you're asking for) there is some instructions for that here: http://wiki.foxycart.com/snippets/add_to_cart_form/add_products_without_colorbox
  • Hi Adam, thanks for the reply. What I would like to do is for when the visitor clicks on Add to Cart, Foxycart will silently add the product to the shopping cart without using colorbox.

    However to still display the products in the shopping cart at all times, I would like to have a mini cart permanently displayed on my shopping page. Is there already a mini cart option available that I can just select in Foxycart or do I have to dive into javascript and HTML? I have only limited knowledge of javascript and HTML so far.

    Thanks
  • fc_adamfc_adam FoxyCart Team
    @jcyin,

    Yeah - for having a shopping cart that always displays you'll need to hook into the javascript cart object, loop through all of the products and build out the cart on your page.

    What version of FoxyCart are you working with?
  • I'm currently working on version 0.7.2, if I had to learn all the necessary javascrip skills to implement the type of mini cart I want, how long might that take? Sorry if the question sounds stupid but I'm really in desperate need of getting this site up and running as soon as possible.

    Thanks
  • fc_adamfc_adam FoxyCart Team
    edited October 2012
    @jcyin,

    If you're starting from nothing, it might be a bit too much to bite off as a first go - but if you're good with picking things up quickly, you might get it done as well.

    As a starting point, this should give you an idea of how it runs: http://pastie.org/private/nylrhdtfvvpepfqev88zrw

    Setting that up would fill in the table with the current cart products on page load, and after each add to cart action. That should give you a basic idea of how it works, but you'll obviously need to edit it from there to get things going how you want them to function and look. You'll also probably need to make some modifications based on the fact you want the products added silently without the colorbox setup.

    If that sounds a bit out of your depth, we could recommend some developers who are familiar with FoxyCart and could help you get this setup in your timeframe - just let us know.
Sign In or Register to comment.