3

I am trying to make it so PayPal is the only option the purchase products, how do I remove the 'Proceed to Checkout' button so this is the only option?

enter image description here

Thanks in advance.

  • 1
    your magento version – Manoj Deswal Jul 14 '17 at 10:04
1

if you want to know in which file you need to hide the text "Proceed to checkout" , you can use Magento template path hints here : system> configuration > Advanced > Developer ....

than switch to current store under Current configuration scope

than enable template path hints under Debug , than you can see from which file the text "Proceed to checkout" is coming from....

you can see below links for more information :

https://stackoverflow.com/questions/24273443/in-magento-1-9-0-0-how-can-i-enable-template-path-hint

http://support.magerewards.com/article/1534-how-do-i-turn-on-template-path-hints

2

There is no such feature to disable 'Proceed to Checkout' button from admin so here are few ways you can disable it

Comment/Remove this code from /public_html/app/design/frontend/VENDOR/THEME/Magento_Checkout/templates/onepage/link.phtml:

<button type="button"
        data-role="proceed-to-checkout"
        title="<?php /* @escapeNotVerified */ echo __('Proceed to Checkout') ?>"
        data-mage-init='{"Magento_Checkout/js/proceed-to-checkout":{"checkoutUrl":"<?php /* @escapeNotVerified */ echo $block->getCheckoutUrl(); ?>"}}'
        class="action primary checkout<?php echo($block->isDisabled()) ? ' disabled' : ''; ?>"
        <?php if ($block->isDisabled()):?>disabled="disabled"<?php endif; ?>>
    <span><?php /* @escapeNotVerified */ echo __('Proceed to Checkout') ?></span>

Another way to remove from layout. Try above if it work for you.

1

Please check checkout.xml file intoyour theme

 <block type="core/text_list" name="checkout.cart.methods" as="methods" translate="label">
                <label>Payment Methods After Checkout Button</label>
                <block type="checkout/onepage_link" name="checkout.cart.methods.onepage" template="checkout/onepage/link.phtml"/>
                <block type="checkout/multishipping_link" name="checkout.cart.methods.multishipping" template="checkout/multishipping/link.phtml"/>
            </block>

comment this code and check it.

0

Create your local.xml file in your theme and put this code

 <?xml version="1.0"?>
 <layout version="0.1.0">
  <checkout_cart_index>
    <reference name="content">            
        <remove name="checkout.cart.top_methods"/>
        <remove name="checkout.cart.methods"/>
    </reference>
    <reference name="checkout.cart">
        <block type="paypal/express_shortcut" name="checkout.cart.methods.paypal_express.top" as="top_methods_only_paypal" template="paypal/express/shortcut.phtml">
            <action method="setIsQuoteAllowed"><value>1</value></action>
        </block>
    </reference>

</checkout_cart_index>
</layout>

and then add <?php echo $this->getChildHtml("top_methods_only_paypal");?> to your your_theme/template/checkout/cart.phtml.

Clear chache and refresh.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.