WOOCOMMERCE END POINTS CONTENT

I have a custom plugin that is integrated with woocommerce. I want to display listing records in the user’s profile and have successfully done so. Creating the end points. refreshing the permalinks. Yet, the call back to drawing the content within the endpoint tab does not appear. Only the dashboard.

function mylistings_account_menu_items( $items )
{
$items[‘mylistings’] = __( ‘Active Listings’, ‘mylistings’ );
return $items;
}
add_filter( ‘woocommerce_account_menu_items’, ‘mylistings_account_menu_items’, 10, 1 );

function mylisting_add_my_account_endpoint()
{
add_rewrite_endpoint( ‘mylistings’, EP_PAGES );
}
add_action( ‘init’, ‘mylisting_add_my_account_endpoint’ );

// THIS DOES NOT APPEAR TO BE WORKING WHY?

function mylistings_information_endpoint_content()
{
echo ‘THIS IS A TEST OF THE CONTENT’;
}
add_action( ‘woocommerce_account_information_endpoint’, ‘mylistings_information_endpoint_content’ );

What am I missing?

Read more here:: WOOCOMMERCE END POINTS CONTENT

Leave a Reply

Your email address will not be published. Required fields are marked *