Products appear twice

We're shifting our Forum based support to a more dedicated support system!

We'll be closing our Forum support from 10th June, 2020 and move to Email Support assistance.

  • If you are a WCFM premium add-ons user, contact us- here
  • Want to know more before buying our add-ons? Send Pre sale queries- here
  • If you are a WCFM free user, please open a support ticket at WordPress.org
  • For WCFM App related queries, reach us- here
From now the forum will be read-only!

Viewing 3 reply threads
  • Author
    Posts
    • #55152
      Aleix Aguilera
      Guest

      Good Morning,

      On the vendor page the products appear twice. The second one under the footer:
      https://www.coolturemag.com/store/aguilera/

      Is there any way to remove it?

      Thanks!

    • #55153
      WCFM Forum
      Member

      Hi,

      Are you using Elementor for creating WC Shop page template?

      Thank You

    • #55318
      Aleix
      Guest

      Yes I do!

    • #55528
      WCFM Forum
      Member

      Hi,

      OK, then please add this code to your child theme’s functions.php –

      add_filter( 'pre_get_posts', function( $query, $that = null) {
      	global $wp_query, $post;
      	$wcfm_store_url = get_option( 'wcfm_store_url', 'store' );
      	$store_name = urldecode( get_query_var( $wcfm_store_url ) );
      	if ( !is_admin() && $query->is_main_query() && !empty( $store_name ) ) {
      		$query->is_archive    = false;
      		$query->is_post_type_archive    = false;
      	}
      	return $query;
      }, 50, 2 );

      Thank You

Viewing 3 reply threads
  • The topic ‘Products appear twice’ is closed to new replies.