Still not searching custom fields
-
Hi!
I’ve just installed your plugin while using a customised theme, but the search results still don’t display anything from custom fields. In case you’re wondering I am using ACF Pro.
I’ve tried deactivating all plugins except ACF Pro and this one, but still no luck.
I’m using the WP get_search_query() function to display results, and my code is as follows:
<?php if (have_posts()) { ?> <header class="page-header"> <h1 class="page-title"><?php printf(__('Search Results for: %s', 'bootstrap-basic'), '<span>' . get_search_query() . '</span>'); ?></h1> </header><!-- .page-header --> <?php // start the loop while (have_posts()) { the_post(); get_template_part('content', 'search'); }// end while bootstrapBasicPagination(); ?> <?php } else { ?> <?php get_template_part('no-results', 'search'); ?> <?php } // endif; ?>
Can you see anything I’m doing wrong? The fields I want to search are in ACF WYSIWYG fields, but still it only shows results from the default content editor or titles.
Thank you in advance for any help with this! Hoping I’m just missing something really stupid …!
Regards, Alex
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Still not searching custom fields’ is closed to new replies.