![]() |
"Product Added" information box above product list when product is added to cart?
Could anyone tell me how I would go about making an information box appear when an item has successfully added to the cart. i.e "Product has been added to your cart"
My website does not redirect to product details page, it just list all products on the page so ideally I want the message to displays above the products list when item has been added. I have had a look around the forums but no-one seems to have a solution. All help gratefully recieved. |
Re: "Product Added" information box above product list when product is added to cart?
|
Re: "Product Added" information box above product list when product is added to cart?
Thank you for your response, however this isn't really what I want.
When the product is added to minicart.tpl from my product list, I would like to display a "product added" message in the same page as the products being viewed. Example: 1. The customer selects category from menu 2. The list of products in that category appear on multiple pages 3. The customer presses Add to Cart button of desired product in product list 4. The cart updates (mincart.tpl) 5. A"product added" message is displayed above product list (like when you save something in x-cart admin?) or perhaps as some type of pop-up box that sits at the mouse position (javascript perhaps?) I believe istockphoto.com is a good example of what I would like. When you add an image to a lightbox (wishlist) a box appears at the cursor with the option to save product to lightbox. When item is saved to lightbox the message box at the cursor displays "item added" I hope this makes sense. Again, any help would be gratefully recieved |
Re: "Product Added" information box above product list when product is added to cart?
Lads, i am looking for the same thing. I can appreciate what X-Cart ezUpsell #96 does, but is overkill perhaps for what we are looking for. After adding an item i dont redirect my clients to the checkout.
Personally all I require is either a popup that says " Item added to cart" or even a similar message that appears on the refreshed item description page, that gives soem sort of notification. Currently my users get confused if the item has actually been added, when they clcik the add to cart button. We have a great Brain pool here - Any suggestions much appreciated. |
Re: "Product Added" information box above product list when product is added to cart?
in product.tpl
find Quote:
and replace with Quote:
|
Re: "Product Added" information box above product list when product is added to cart?
I tried the above but it didn't seem to work? The site I would like to implement this change is a 4.1.2 site, maybe that's why?
Where should the alert be seen? Any further help would be great...I am really hoping to solve this one. It would solve alot of customer confusion Cheers |
Re: "Product Added" information box above product list when product is added to cart?
Fantastic - this worked a treat for me (V4.0.19). Just what i needed - the brains trust comes to the rescue again ;)
|
Re: "Product Added" information box above product list when product is added to cart?
Confirm also works in 4.1.8
|
Re: "Product Added" information box above product list when product is added to cart?
i would recommend against the code i gave you before, since i believe the alert will still come up when there is an error with adding the product
instead in include/cart_process.php (or cart.php for 4.0.x), after Code:
if ($productid && $amount) { echo "<script>alert('Product has been added.')</script>"; |
Re: "Product Added" information box above product list when product is added to cart?
New code works like a charm. Thanks so much!!
I was wondering however if there is any way to display this alert box without/before the refresh. At present when customer presses "add to cart" a white page and the alert follows and a "if page does not refresh...etc" page displays . I would like to achieve the following.... 1. The add to cart button is pressed, 2. Alert box is displayed on the current page rather than on the blank. 3. Customer presses ok on alert box 4. Then site refreshes - if it has to. This would be a fantastic additive to X-cart, if the box could be displayed on current page where customer is adding product from. I know I've been waiting for this for ages!!!!! All help greatfully recieved. |
Re: "Product Added" information box above product list when product is added to cart?
forgot about that white page...i will have a look at the cart php page again
|
Re: "Product Added" information box above product list when product is added to cart?
The popup message works great for a single product view (4.17 Crystal Blue), but don't work on the products list for the "buy it now" button. Any ideas here?
|
Re: "Product Added" information box above product list when product is added to cart?
Jinkies! finally find something i can use.... but
Is there a way to get this alert message to appear for a few seconds then close? Yes yes, i know theres mods for sale. A bit tapped for now on the funds. Thanks all :D/ |
Re: "Product Added" information box above product list when product is added to cart?
you would have to use javascript popup window with a timer (or a div if you so choose) to close instead of an alert, since you can close a window (or div) but not an alert
|
Re: "Product Added" information box above product list when product is added to cart?
err, thanks ineb
anychance on how to go about writing this? So far i havent touched much of javascript because im not familar withit. Only changes on things such as above i'll try. JS always seemed like the bully of the code not wanting to be bothered with. Thanx for your reply! :wink: |
Re: "Product Added" information box above product list when product is added to cart?
currently working on a customer's mod, so i would have to get back to this later on
|
Re: "Product Added" information box above product list when product is added to cart?
I put up the mod at http://xcart-toolshop.com/itemaddedmsgmod.html
|
Re: "Product Added" information box above product list when product is added to cart?
This code looks really promising. But I am a little confused by the code you provide after -
"now in a template and location you so choose, add..." Could you provide an example? What and where should that code be placed? Something like products.tpl? I would really like this to work in the products list. Also, would this mod be 4.1.2 and 4.1.9 compatible as I see you are using Pro 4.0.18. Thanks for your help |
Re: "Product Added" information box above product list when product is added to cart?
its not product specific, so if you want to put it in products.tpl you can but it wont be on a per product basis, so you would put it before the {section}{/section} (or maybe it was {foreach}{/foreach}) loop or after...i would suggest putting it in the minicart, somewhere visible to the customer that wont get mixed up with other info
an item added to cart will imply that any item was added, so putting it next to a single product in a products list is not a good idea, which is why i suggested putting it before the loop you can make it product specific but that requires more code since you need to check not only for the product but match the product options as well this code was made for 4.1.x, 4.0.x should be similar but i havent bothered to look yet what this code does is it will display the message for 5 seconds once the script finishes loading (not to be mistaken for a complete page load) and then clears it, you can adjust the time if you so choose |
All times are GMT -8. The time now is 07:49 PM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.