Hi there,
I checked and I’m correct, the hook x_after_masthead_end
is not working since your current setup pick ups the legacy templates. The working code should be like this
add_action('x_after_view_global__slider-below', 'display_the_banner_here');
function display_the_banner_here () {
if ( x_is_shop() || x_is_product_category() || x_is_product_tag() ) {
//Add your banner code here, it's usually the function added/attached to do_action( 'woocommerce_after_main_content' );
}
}
Now, you need to find out the banner code that should be displayed there, because this line triggers internal server error.
$wcvendors_pro->wcvendors_pro_vendor_controller->store_main_content_header();
PHP Fatal error: Call to a member function store_main_content_header() on null in /home/pramodg29/public_html/Mangtum.com/wp-content/themes/x-child/functions.php on line 474
Hence, it’s not the correct one and I can’t tell which is correct since it’s your Vendor pro plugin. I also tried this one,
do_action('woocommerce_before_main_content');
But it’s not working, so my question is does this one really works?
add_action( 'woocommerce_before_main_content', array( $wcvendors_pro->wcvendors_pro_vendor_controller, 'store_main_content_header'), 1 );
That code is to integrate your vendor pro to woocommerce hooks. And we call do_action()
to manually trigger woocommerce_before_main_content
action, in short, it should be compatible now. I think you should contact the plugin author for that. The above code should display it, but their codes aren’t working.
Thanks!