Can you explain why? That will prevent users accessing sections.
It broke the webpage layout.
Wouldn’t it be better to fix the layout by styling it then 🙂 See if your theme has an update available.
Hi okay.
I understand why adding this nav-links, but my layout is a full width-layout, and this works very useful for my case.
This nav-links are new in the latest WC version?
Very useful blogpost.
Thank you for this info Mike.
I having a somewhat different issue as the orders
and payment-methods
endpoints are returning 404 pages for me. I looked into the woocommerce_account_orders_endpoint
hook and it seems like the page is re-directing to a 404 before the woocommerce_account_orders
method is even called.
Make sure to re-save permalinks which can resolve most 404s. Post your own thread if stuck.
For future readers looking for a legitimate way to remove the navigation you may remove the action hook:
remove_action(
'woocommerce_account_navigation',
'woocommerce_account_navigation'
);
It is also a pluggable function which means you can supplement it with something else if you choose:
function woocommerce_account_navigation() {
// The code here will *replace* the account navigation
}
For more information:
-
This reply was modified 7 years, 5 months ago by Howdy_McGee. Reason: Testing code formatting
-
This reply was modified 7 years, 5 months ago by Howdy_McGee. Reason: Code Formatting :)
Thank you for the tip @howdy_mcgee
I removed the navigation by adding the remove_action function in my theme’s function.php and it work.
However, it leaves a blank space where the navigation was. Is there an easy way to make the content stretch full-width?
Thanks
Dom
Well, I found an answer to my question. I just added this css line.
.woocommerce-MyAccount-content {width:100% !important;}
gf
(@gflwrg)
This is well helpful. Thanks to everyone who contributed to these solutions.