Skip to content

Instantly share code, notes, and snippets.

@grola grola/functions.php
Created Feb 7, 2018

Embed
What would you like to do?
Woocommerce - add link to my account in minicart
<?php
add_action( 'woocommerce_widget_shopping_cart_buttons', 'studiowp_woocommerce_widget_shopping_cart_buttons', 30 );
function studiowp_woocommerce_widget_shopping_cart_buttons() {
echo '<br/>';
echo '<a href="' . esc_url( get_permalink( get_option('woocommerce_myaccount_page_id') ) ) . '" class="button my-account wc-forward">' . esc_html__( 'My Account', 'woocommerce' ) . '</a>';
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.