Jump to content
Sign in to follow this  
Paul_w

Contribution: Remind customer update cart on change quantity

Recommended Posts

Remind Customers to click 'Update' button when updating quantities in cart.

 

This is a pretty simple mod that will show a bold red text message above the

'update' button on the shopping cart page as soon as the customer enters a new

product quantity in the update quantity input field, it is hidden at all other times. Helps to avoid confusion with newbie customers!

 

This mod requires the customer to have Javascript enabled, fails gracefully if not. Tested in IE 5 + 6, Mozilla 1x, Opera 6 + 7, also works in NN4 but doesn't look quite as good.

 

Hope somebody else will like this!

 

Paul

Share this post


Link to post
Share on other sites

Hi

 

My site is still in development, due to this and also to avoid competitors prying eyes I have the whole site .htaccess protected at present.

 

However you can see before and after screenshots below:

 

before.gif

 

After clicking in the quantity or delete box:

after.gif

 

Paul

Share this post


Link to post
Share on other sites

Hi,

Installed this (welll not quite an install really but..) fantastic, suprising how something so simple can make an impact. Thanks for posting this, I am sure you'll have many more who feel the same.

 

Regards

 

Ed

i-netmedia


osC junkie...

-------------------------------------------------------

Bluepay Weblink Gateway: /contributions,993

Internetsecure: /contributions,951

Losing my virginity to osC: /contributions,58/

Share this post


Link to post
Share on other sites

Hi Paul,

 

Could you please give me a link to your contribution so I can install.

 

Thank you in advance,

Mark

Share this post


Link to post
Share on other sites

Hi.

 

I just installed this contribution and it is very nice! Is it possible to have it in different languages?? I do not know how to express it, but I want to have it in English and other language.

 

Thank you!!

Share this post


Link to post
Share on other sites

Download the mod

 

Change the javascript into

 

<script type="text/javascript">

<!--

on = "<?php echo TEXT_SHOPPINGCART_UPDATE; ?>";

off = " ";

function advisecustomer(advise_status) {

document.cart_quantity.advise.value = advise_status;

}

-->

</script>

 

Go to your language directory and open shopping_cart.php.

 

Add define('TEXT_SHOPPINGCART_UPDATE', 'To update quantity you must click 'Update' button below:');

 

and put in your own words and your done.

 

You can also change the background into transparency

 

Change

 

<td><input type="text" name="advise" size="30" maxlength="100" style="width:340px; font-size:10px; background-color:white;color:red;font-weight:bold;border:0px;" value="" /></td>

 

into

 

<td><input type="text" name="advise" size="30" maxlength="100" style="width:340px; font-size:10px; background-color:transparent;color:red;font-weight:bold;border:0px;" value="" /></td>

Share this post


Link to post
Share on other sites

Hi, I got it work! Thank you very much. It was about 'Update'. When I took '' off, it worked.

 

 

define('TEXT_SHOPPINGCART_UPDATE', 'To update quantity you must click 'Update' button below:');

 

 

Great contribution!

Thanks again. :oops:

Share this post


Link to post
Share on other sites

Great! Does anybody know how to get this working on the new MS2.2? It seems as if th ecode has changed and now I can't get it working.

 

Thanks,

Priest

Share this post


Link to post
Share on other sites

what about when people check the "Remove" checkbox?

many customer don't know they need to update the page too...

 

cheers

emiliano


patagonia, argentina

Share this post


Link to post
Share on other sites

Yes, originally this contrib was upgraded to also work so that when they changed quantity or the remove box, it reminds them to click update.

 

The only problem with it now, is that it doesn't seem to be working with MS2.2 because of the code changes.

 

~P~

Share this post


Link to post
Share on other sites

Did anyone figure out the changes to make this contr. work with MS2

 

I would love to implement it. Please let me know

 

Thanks

Share this post


Link to post
Share on other sites

Hi,

I rewrote Paul's contribution for MS 2 and did a few other changes - I'll just copy & paste from the readme file:

 

*******************************************************

Differences to previous versions

*******************************************************

 

- Runs with osCommerce 2.2 MS2

 

- Multilingual, makes use of language files

 

- The reminder message will not disappear when a user clicks anywhere outside of the form inputs

 

- The reminder message will not be displayed inside of a form's text input with border set to zero, as this is not supported by some browsers such as Opera and older Netscape versions. A span-tag along with DHTML is used instead, which improves usability and appearance.

 

- Browsers without JavaScript and older browsers (like Netscape 4 and earlier, MS Internet Explorer 3 and earlier) will permanently display the reminder.

 

- English and German install instructions and phrases for the language files

 

The contrib is still availible at

http://www.oscommerce.com/community/contributions,1008 B)

 

Cheers,

Nils

Share this post


Link to post
Share on other sites

Thank you very much Nils for the update! I had to remove the "" on "Update" to get it to work for me.

 

Just in case someone else is having errors, here is what I had to change.

 

Original Code:

 define('TEXT_UPDATE_WARNING', 'Please confirm any changes by clicking the "Update" button before checking out');
 

 

New Code:

 define('TEXT_UPDATE_WARNING', 'Please confirm any changes by clicking the Update button before checking out');
 

 

It works beautifully and now I shouldn't have to worry about orders being sent with the wrong quantities! :D

 

Thanks again!

Kamie

Share this post


Link to post
Share on other sites

Kamie,

 

thanks for the pointer. Don't know how this one slipped past my "QA"... ;)

The German instructions didn't have this bug. Anyways, I uploaded a new fixed version with correct HTML-Quotes

 define('TEXT_UPDATE_WARNING', 'Please confirm any changes by clicking the "Update" button before checking out');

Not using the quotes at all is a possible solution too, of course, but the new downloadable pack Customer Update Cart Reminder v2.0a has the solution above.

 

Nils

Edited by Nils P.

Share this post


Link to post
Share on other sites

Hi Nils,

 

Okay, your solution is much better than mine! I took the easy route. :D Thank you very much for updating everything so quickly with the new code. I have now updated mine so it now reads "Update".

 

Thanks again for your work.

 

Kamie

Share this post


Link to post
Share on other sites

Hi all,

 

I thank you all for the nice contribution to remind customer NOT to forget to do something I will implementit if I can't find any other solusion.

 

However, I have noticed that many shopping cart instead of having to tick in the box and UpDate Button, Have just one small image that clicking on it should Automatically update the cart. (deleting the product)

 

I just had a thought and I have been trying to do it... Wouldn't just be easier to have something like that in stead of having to REMIND customer what to do next?

 

I have also seen a contribution that automatically would change the number of products and with this One added, would just get read of the update button altogether....

 

JUST A THOUGHT please forgive me if you didn't want to this little input in this Topic..

 

Thank you

 

Salvo

Share this post


Link to post
Share on other sites
However, I have noticed that many shopping cart instead of having to tick in the box and UpDate Button, Have just one small image that clicking on it should Automatically update the cart. (deleting the product)

Yes, that's for deleting the product, but not for changing the amount. There's an older thread about this here somewhere where team members discuss this but IIRC, hpdl decided to do it the way it is now, because then you can perform several changes, delete and change amounts, and only have to click the update button once for all changes. So I decided to stay with this. Technically it's no problem to implement a delete button for every row, and I gave it some thought, but decided to stay with the checkbox method.

 

I have also seen a contribution that automatically would change the number of products and with this One added, would just get read of the update button altogether....

I'd appreciate if you could find a link to that one, I'd be interested how they did it. At the moment I didn't implement automatic updating for two reasons: technically, when exactly should the code "know" that now it is time to update? Example, if a customer wants to change the amount from 250 to 75, when to update?

One solution, an automatic update when a cutomer clicks on "checkout" will be ok for a part of the customers, the others are used to updates only having effect when you confirmed them explicitly by clicking on a button (like Amazon and all other "big" sellers have it), will be really annoyed. Plus, auto-update will bring about legal issues in many countries, so it's not really an option for an international cart.

 

I gave all this quite some thought before I updated the contribution. I actually pretty much had the same thoughts as you did, but the best solution I could come up with is in the contrib now, and I think it's a good solution. Delete buttons might be an option though, maybe I'll add that as a optional installation in a later version of "Customer Update Cart Reminder".

 

Thanks for your input.

Nils

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×