In the previous post, I walked through the process of adding a custom WooCommerce menu to the My Accounts page. It’s straightforward enough, but if you’re creating a custom menu item, then you’re likely going to need a custom WooCommerce page.
That is, you’re going to want to have a page that corresponds to the menu item so that people who are logged into your store can view something related to the custom menu item that’s been added.
Granted this isn’t always the case, but if you’re adding a custom menu, the odds are you’re going to be adding a custom WooCommerce page. The thing is, WooCommerce expects these pages – which are actually templates – to reside in a specific location.
And if you’re distributing a plugin for others to use, making sure the template is in the right place should be done programmatically.
Continue reading