I was trying to make the checkout button in my cart (dispatch=checkout.cart) larger but found that changing the css for it also affected other buttons, like add to cart. I think I figured out how to create a special class for the checkout button, but there is a ton of css to copy and edit.
Is it easier to replace this with an image? If there is an easier way, someone please share…
PROBLEM - this not only changes the checkout button on the cart, it also changes the checkout button on the notification window that pops up when you add an item to the cart. I initially couldn’t find where to change that, but I have it now so I added instructions below.
In buttons/button.tpl
Find:
<br />
{if $but_role == "action"}<br />
{assign var="suffix" value="-action"}<br />
{assign var="file_prefix" value="action_"}
```<br />
<br />
After it, add our new class... I call it checkout - this is what is appended to the class's value<br />
(for example button-checkout, button-submit-checkout)<br />
I'm not sure if the part in red is needed. Anyone know? Mine is working this way so I left it.<br />
```php
{elseif $but_role == "checkout"}<br />
{assign var="suffix" value="-checkout"}<br />
[COLOR="Red"]{assign var="file_prefix" value="action_"}[/COLOR]
```<br />
<br />
Now for the hard part... Go into styles.css and styles.base.css and find the button-action css and copy it for button-checkout. Anywhere there an -action suffix, you'll need a copy of it for your -checkout css.<br />
<br />
After that's all done you can switch on the -checkout class for that checkout button by going to buttons/checkout.tpl<br />
<br />
Replace "action" with "checkout" (in red below):<br />
```php
{include file="buttons/button.tpl" but_text=$lang.checkout but_onclick=$but_onclick but_href=$but_href but_target=$but_target but_role="[COLOR="Red"]action[/COLOR]"}
```<br />
<br />
After that change, I had to clear cache to see it take effect. <br />
<br />
If your css isn't right you can go back to buttons/checkout.tpl and change the role back to "action". ;)<br />
<br />
**********************<br />
<br />
I changed the button in the product notification pop-up to "View Cart" and linked it to the cart by doing this....<br />
<br />
Created a new template: buttons/_view_cart.tpl with this content:<br />
```php
{include file="buttons/button.tpl" but_text=$lang.view_cart but_onclick=$but_onclick but_href=$but_href but_target=$but_target but_role="action"}
```<br />
<br />
Then, in views/products/components/product_notification.tpl:<br />
<br />
```php
{include file="buttons/checkout.tpl" but_href="$index_script?dispatch=checkout.checkout"}
```<br />
<br />
Changed to:<br />
```php
{include file="buttons/_view_cart.tpl" but_href="$index_script?dispatch=checkout.cart"}