How to add "check out" button on: http://hopmanhome.com/zen/index.php?...&products_id=2
(in stead of the add to the cart button)
Thanks for your help!
Printable View
How to add "check out" button on: http://hopmanhome.com/zen/index.php?...&products_id=2
(in stead of the add to the cart button)
Thanks for your help!
Go to:
includes/languages/english/button_names.php
edit around line 30:
and change toCode:Line #30 : define('BUTTON_IMAGE_IN_CART', 'button_in_cart.gif');
Save and upload to your server. Make sure to use the override directory otherwise it will get overwritten during an upgrade. Simply create a folder using your template name (such as classic) and upload your button_names.php file to that folder.Code:Line #30 : define('BUTTON_IMAGE_IN_CART', 'button_checkout.gif');
I have made the change and indeed the button changed from "add to cart" to "check out"
http://hopmanhome.com/zen/index.php?...03df4ce2c06976
I guess the next step is to change the functionality since it still land on the shopping cart if you press on the check out button.
How to do that?
You're wanting the button changed, which you have done. But also you want the item to be added to the cart and the customer to be taken directly to Checkout? Do you have other products for sale? Or maybe other products will be available one day? Reason I ask is by taken them directly to the Checkout you are basically saying you can't buy anything else. If you do offer more products then the customer would have to leave the Checkout and go back into your store to buy more stuff.
Just my thoughts
I do not have other products to sale.
The question is how to implement it?
I just tried the following and it worked.
Make sure your Admin -> Configuration -> My Store -> Display Cart After Adding Product = True
Open file:
/includes/init_includes/init_cart_handler.php
Look for the following:
Change: FILENAME_SHOPPING_CART to FILENAME_CHECKOUT_SHIPPINGPHP Code:
if (DISPLAY_CART == 'true') {
$goto = FILENAME_SHOPPING_CART;
Once this is done and your customer clicks that button to add the item to the cart, it adds it and takes them directly to Checkout. Since Checkout requires a login process, it asked for a username/password on my site. Maybe yours is setup different and it will not ask.
Make a backup of that file before doing anything. If this doesn't work or it's wrong advice, you will be able to just restore the backup file and be back to where you are now.