Answer the question
In order to leave comments, you need to log in
[[+content_image]]
How do I change the "Add to Cart" button to "Checkout"?
Shop on MiniShop2.
The "Add to Cart" button is implemented as standard:
<button type="submit" class="btn btn-default" name="ms2_action" value="cart/add">
ms2_frontend_add_to_cart
</button>
Answer the question
In order to leave comments, you need to log in
Decision.
Don't forget JQ.
<button type="submit" class="btn btn-default add_cart_first" name="ms2_action" value="cart/add">
ms2_frontend_add_to_cart
</button>
<a class="hide add_cart_second" type="submit" href="" >
Оформить заказ
</a>
<script>
$(document).on('click', '.add_cart_first', function(e) {
$(this).hide();
$(this).next('.add_cart_second').show();
});
</script>
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question