| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | Mark Forums Read | User manuals | Login |
Add to Cart Popup | Backporting to 4.4.X | ||||
|
|
Thread Tools | Search this Thread |
#1
|
|||||||||
|
|||||||||
Add to Cart Popup | Backporting to 4.4.X
I think one of the juiciest features of 4.5.X is the addition of the new Add_to_cart_popup module. It is the best of both worlds. Traditionally you have to choose whether you want to redirect to cart and possibly lose out on additional impulse buying, or keep them on page with the ajax cart update and potentially confuse your visitor about whether the item is added or not. I have seen most of the bigger brands out there adopt this popup method. It also gives you an option for upselling.
So what do users with 4.4.X do? Upgrade their highly customized carts? No longer! I have been contracted to backport this module to a 4.4.4 site, and I am going to track my progress and steps in this thread. Stay tuned!
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey XcartGuru X-cart Tutorials | X-cart 5 Tutorials Check out the responsive template for X-cart. |
|||||||||
|
#2
|
|||||||||
|
|||||||||
Re: Add to Cart Popup | Backporting to 4.4.X
Step 1
Download a 4.5.X distribution from your Qualiteam helpdesk. We need to get the files for the module. The two folders you are looking for are: /modules/Add_to_cart_popup/ and /skin/common_files/modules/Add_to_cart_popup/ Copy the contents of these two folders and place them in your xcart directory, being sure to keep the paths and folder structure intact. While you are at it, grab this file too: /include/func/func.minicart.php It helps if you create a folder on your computer that mimics the site structure and contains all the new files and the ones we are going to edit in the next step. This will let you upload all your changes to your dev site in one step, and after testing you can do the same for your live site.
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey XcartGuru X-cart Tutorials | X-cart 5 Tutorials Check out the responsive template for X-cart. |
|||||||||
#3
|
|||||||||
|
|||||||||
Re: Add to Cart Popup | Backporting to 4.4.X
Step 2
Now we are going to edit some files, to include the module functionality in the existing PHP files and templates. Be sure to create a backup of the existing file before you edit it. I like to name my backup files something meaningful like filename.extension.bak.Add_to_cart_popup so I can identify what I was doing when I edited that file. Edit /cart.php: Find: PHP Code:
After add: PHP Code:
Before: PHP Code:
Find: PHP Code:
PHP Code:
PHP Code:
Edit /include/product_modify.php: Find: PHP Code:
PHP Code:
Find: PHP Code:
PHP Code:
PHP Code:
Find: HTML Code:
HTML Code:
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey XcartGuru X-cart Tutorials | X-cart 5 Tutorials Check out the responsive template for X-cart. |
|||||||||
|
#4
|
|||||||||
|
|||||||||
Re: Add to Cart Popup | Backporting to 4.4.X
Step 3
Now we need to update the database with the module settings and added language variables. To do this visit Tools > Patch/Upgrade section of your X-cart admin. Look under the heading "Apply SQL Patch". In the text box labeled SQL query(ies) paste these queries: INSERT INTO xcart_config VALUES ('enable_upselling','Upselling products','Show_Both','Add_to_cart_popup',10,'sele ctor','Show_Both','Show_Random:lbl_show_randomly_s elected_products\nShow:lbl_show_upselling_products \nShow_Both:lbl_show_upselling_and_random\nHide:lb l_do_not_show_upselling_products',''); INSERT INTO xcart_modules VALUES (98,'Add_to_cart_popup','This module allows your customers to see what they have added to cart along with upselling products.','Y'); INSERT INTO xcart_languages VALUES ('en','module_name_Add_to_cart_popup','Add To Cart Popup','Modules'); INSERT INTO xcart_languages VALUES ('en','lbl_show_upselling_and_random','Show upselling + random products','Labels'); INSERT INTO xcart_languages VALUES ('en','lbl_show_randomly_selected_products','Show random products','Labels'); INSERT INTO xcart_languages VALUES ('en','lbl_show_upselling_products','Show upselling products','Labels'); INSERT INTO xcart_languages VALUES ('en','lbl_do_not_show_upselling_products','Do not show additional products','Labels'); INSERT INTO xcart_languages VALUES ('en','lbl_item_added_to_cart','item added to cart','Labels'); INSERT INTO xcart_languages VALUES ('en','lbl_items_added_to_cart','items added to cart','Labels'); INSERT INTO xcart_languages VALUES ('en','lbl_proceed_to_checkout','Proceed to checkout','Labels'); Alternatively you can use phpMyAdmin for this task, or download the file attached to this post and upload it using the "Patch File" Upload button. (you may need to rename it to .sql instead of .txt, not sure haven't tried it yet)
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey XcartGuru X-cart Tutorials | X-cart 5 Tutorials Check out the responsive template for X-cart. |
|||||||||
|
#5
|
|||||||||
|
|||||||||
Re: Add to Cart Popup | Backporting to 4.4.X
You're Done!
You may want to run yoursite.com/cleanup.php. Now you can go to Settings > Modules and you should see Add To Cart Popup at the top of the list. If you don't then you might have forgotten to run the sql patch above. Good luck, hope it helps. Mike White, signing off...
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey XcartGuru X-cart Tutorials | X-cart 5 Tutorials Check out the responsive template for X-cart. |
|||||||||
|
#6
|
|||||||||
|
|||||||||
Re: Add to Cart Popup | Backporting to 4.4.X
Great job Mike. Keep going!
__________________
X-Cart Next: Business 5.2 (learning and testing) X-Cart Classic: Gold and Gold Plus 4.7 Lots of Modules and Customizations OS in use: Red Hat Enterprise, Fedora, CentOS, Debian, Ubuntu, Linux Mint, Kali Linux Ideas for Server configuration (basicaly): Nginx/Pound (reverse proxy), Apache/Nginx (webserver), Squid/Varnish (cache server), HHVM or (PHP-FPM + PHP 5.6 + opcache), MariaDB/Percona MySQL Server, Redis (storing sessions) You can catch my ideas here: http://ideas.x-cart.com |
|||||||||
|
#7
|
|||||||||
|
|||||||||
Re: Add to Cart Popup | Backporting to 4.4.X
Very nice Mike and thank you! Going to bookmark this thread
__________________
If you need professional help on your x-cart site or any website. Feel free to PM me or Skype me to discuss your project. |
|||||||||
|
#8
|
|||||||||
|
|||||||||
Re: Add to Cart Popup | Backporting to 4.4.X
Excellent
Just make sure "Redirect customer to cart after adding a product" (Setting/General) is switched off, or you'll never see the popup! Took me about 15 minutes to work that one out
__________________
Darren Kierman Carlisle Glass (http://www.carlisleglass.co.uk/) ... running X-Cart Gold 4.4.5 [unix] |
|||||||||
|
#9
|
|||||||
|
|||||||
Re: Add to Cart Popup | Backporting to 4.4.X
Quote:
I'm using 4.5.3 gold plus and this switch caused me 12+ hours of insanity. see: http://forum.x-cart.com/showthread.php?t=65209 THANK YOU for pointing this out!!! I have been searching the forum in every way, and this did not show up. GEEZ -- turning this switch OFF should be a FRONT AND CENTER WARNING in the Add To Popup documentation, you think? If this switch is set, the module will not function. Hopefully, this thread helps someone searching. For the search engines: Add To Cart Popup Not Working Redirect customer to cart after adding a product setting THANK YOU, THANK YOU THANK YOU!!!
__________________
xcart 4.5.4 gold+ w/x-payments 1.0.6; xcart gold 4.4.4 |
|||||||
#10
|
|||||||
|
|||||||
Re: Add to Cart Popup | Backporting to 4.4.X
I hope someone is still paying attention to this thread. I'm currently trying to modify products_t.tpl to remove all the <table> related tags so I can use <div> tags instead. If I do this, clicking the Buy Now button will add products to the cart, but the Add To Cart popup box no longer open. It seems that the popup module relies on <table> codes? Anyone have any insight as to why this might be, and better yet, which other files I need to modify?
__________________
x-cart v 4.5.4 |
|||||||
|
Thread Tools | Search this Thread |
|
|
|
|||
X-Cart forums © 2001-2020
|