Answer the question
In order to leave comments, you need to log in
How to parse a WooCommerce endpoint?
Good day everyone!
The task is, how to correctly ask the endpoint from under the woocommerce_my_account hook (being on the WooCommerce account page)?
If parsing the mask with GET in the request is easy:
wordpress/my-account?view-order=1673
then how to parse this?:
wordpress/my-account/view-order/1673/
The function
works on the first page and on the second, but in the second option, I can't get the order ID because the URL mask can be unpredictable. The variable $order is not declared in
is_wc_endpoint_url( 'view-order' )
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question