Home Forums Front-end Issues Disable custom field on pagination pages (elementor)


Disable custom field on pagination pages (elementor)

  • Hi,

    I’m stuck and can’t deal with the duplication of content.

    I have an extra field created in ACF that displays on the product archive template above the products. I don’t want this field to display on pagination subpages, ie other than the first product category subpage. Product category archive created in theme builder. The theme used is underscores.

    The site is elementor pro + woocommerce + ACF.

    Can anyone direct me to the correct custom code that will solve my problem?

  • I cannot tell you how to apply this to a page template created in elementor theme builder, that would be a questions specific to elementor.

    All I can tell you is how you would do this using PHP code

    $current_page = get_query_var('paged', 1);
    if ($current_page == 1){
      // content only on first page

    I did find this, don’t know if it will be helpful or not:

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.