ElasticPress icon indicating copy to clipboard operation
ElasticPress copied to clipboard

BUG: Custom Search Results

Open gwhitehead opened this issue 4 weeks ago • 2 comments

Describe the bug

Custom Search results do not appear to be working as they should be. As an example, we are putting in the exact product name of a given product and trying to set specific pages as needing to show at the top. If we leave the last 0 off of the product name the results come up but when we add the zero to the end of the product name it doesn't show the results of the specific search term entered into the custom search results section.

To give an example: A12340 is a product name. We add custom search for both A1234 and A12340 yet the one with the 0 is not working and also is not showing up in the search results even though the post title matches exactly what is being searched for.

We do have JavaScript customization going on for the auto-suggest results and I tried removing that custom code in the attempt to see if that was causing the issue but the same thing is still happening.

Steps to Reproduce

  1. Go into Custom Search under ElasticPress.
  2. Add in a specific Search Query
  3. Set the pages we want to show for the given search term
  4. test on front end and we are not seeing the results as expected.

Screenshots, screen recording, code snippet

No response

Environment information

No response

WordPress and ElasticPress information

## Failed Queries ##

ElasticPress.io

Allowed Autosuggest Parameters

post-types: cool_timeline, expandedcta, mec-events, news, page, post, product, product-category, and webinar post-status: acf-disabled and publish search-fields: post_title, post_content, terms.ep_custom_result.name, post_title.suggest, terms.post_tag.name, term_suggest, post_excerpt, meta.indexable_content.value, and terms.category.name returned-fields: ''

WordPress

WordPress Environment

wp_version: 6.8.3 home_url: https://www.doble.com site_url: https://www.doble.com is_multisite: false theme: Doble (1.1) plugins: ACF Autosize (2.0.15), ACF Content Analysis for Yoast SEO (3.2), Activity Log (2.11.2), Admin Columns Pro (6.4.22), Advanced Custom Fields: Font Awesome (4.1.2), Advanced Custom Fields: Gravity Forms Add-on (1.3.8), Advanced Custom Fields: Nav Menu Field (2.0.0), Advanced Custom Fields: RGBA Color (1.3.1), Advanced Custom Fields Multilingual (2.1.5), Advanced Custom Fields PRO (6.5.1), Advanced Editor Tools (5.9.2), Archives for Custom Post Types (1.0.2), Authors Widget (2.4.8), Category Order and Taxonomy Terms Order (1.9), Classic Editor (1.6.7), Classic Widgets (0.3), Cool Timeline Pro (4.6), Disqus Conditional Load (11.1.2), Duplicate Menu (0.2.2), ElasticPress (5.2.0), Enable Media Replace (4.1.6), Flying Scripts: Delay JavaScript to Improve Site Speed & Performance (1.2.4), GP Preview Submission (1.3.24), Gravity Forms (2.9.17.1), Gravity Forms Multilingual (1.8.2), Gravity Forms reCAPTCHA Add-On (2.0.0), Gravity Forms Sticky List (1.5.2), Gravity PDF (6.13.3), MEC Fluent-view Layouts (1.7.0), Menu Item Duplicator (1.0.2), MimeTypes Link Icons (3.2.20), Modern Events Calendar (7.25.0), Page Restrict (2.5.5), Post SMTP (3.6.1), Post Types Order (2.3.7), PrettyLinks (3.6.17), Redirection (5.5.2), ShiftNav Pro - Responsive Mobile Menu (1.8.2), Shortcodes Ultimate Pro (7.4.5), ShortPixel Image Optimizer (6.3.3), Spellbook (3.0.14), UberMenu 3 - The Ultimate WordPress Mega Menu (3.8.5), UpdraftPlus - Backup/Restore (1.25.7), User Role Editor (4.64.5), White Label CMS (2.7.8), Widget Output Filters (1.2.0), Wordfence Security (8.1.0), WP Gravity Forms Salesforce Pro (1.5.1), WPML ElasticPress (2.0.4), WPML Media Translation (2.7.7), WPML Multilingual CMS (4.7.6), WPML Sticky Links (1.5.5), WPML String Translation (3.3.3), WPS Hide Login (1.9.17.2), YIKES Simple Taxonomy Ordering (2.3.4), Yoast Duplicate Post (4.5), Yoast SEO (25.9), and Yoast SEO Premium (25.9) revisions: 0

Server Environment

php_version: 8.2.29 memory_limit: 512M timeout: 43300

Indexable Content

Doble Engineering Company — https://www.doble.com

post_count: 554 page_count: 650 product-category_count: 175 webinar_count: 30 mec-events_count: 935 cool_timeline_count: 103 news_count: 326 product_count: 725 post_meta_keys: 1 page_meta_keys: 1 product-category_meta_keys: 1 webinar_meta_keys: 1 mec-events_meta_keys: 0 cool_timeline_meta_keys: 0 news_meta_keys: 0 product_meta_keys: 1 total-all-post-types: 1 distinct-meta-keys: ep_exclude_from_search

ElasticPress

Settings

host: https://wpe-dobleeng-l9eaxezi.us-east-2.wpe.clients.hosted-elasticpress.io index_prefix: wpe-dobleeng-l9eaxezi- language: site-default per_page: 50 network_active: false

Timeouts

request_timeout: 5 index_document_timeout: 15 bulk_request_timeout: 30

Elasticsearch Indices

wpe-dobleeng-l9eaxezi--doblecom-post-1

health: green status: open index: wpe-dobleeng-l9eaxezi--doblecom-post-1 uuid: B3fN4BrpTtWnvs36vXHiEg pri: 1 rep: 1 docs.count: 1254 docs.deleted: 94 store.size: 21.7mb pri.store.size: 10.8mb dataset.size: 10.8mb total_fields_limit: 5000 analyzer_language: english stop_language: english snowball_language: English

wpe-dobleeng-l9eaxezi--doblecom-post-1-zh-hans

0: true

wpe-dobleeng-l9eaxezi--doblecom-post-1-fr

health: green status: open index: wpe-dobleeng-l9eaxezi--doblecom-post-1-fr uuid: heEdgb8ISGqR1ntV9W5skQ pri: 1 rep: 1 docs.count: 1133 docs.deleted: 75 store.size: 23.1mb pri.store.size: 11.5mb dataset.size: 11.5mb total_fields_limit: 5000 analyzer_language: french stop_language: snowball_language: French

wpe-dobleeng-l9eaxezi--doblecom-post-1-es

health: green status: open index: wpe-dobleeng-l9eaxezi--doblecom-post-1-es uuid: x6zvQD0cT4m50Z3rvaPZcQ pri: 1 rep: 1 docs.count: 1136 docs.deleted: 73 store.size: 27.7mb pri.store.size: 13.8mb dataset.size: 13.8mb total_fields_limit: 5000 analyzer_language: spanish stop_language: snowball_language: Spanish

Last Sync

2025/07/23 10:27:56 pm

method: WP Dashboard is_full_sync: No end_date_time: 2025/07/23 10:32:38 pm total_time: 0 hours, 4 minutes, 43 seconds total: 1055 synced: 1055 skipped: 0 failed: 0 errors: array ( ) trigger: manual final_status: success

Feature Settings

ACF Repeater Field

active: true force_inactive: false

Autosuggest

active: true autosuggest_selector: .ep-autosuggest endpoint_url: force_inactive: false trigger_ga_event: 1

Custom Search Results

active: true force_inactive: false

Filters

active: true force_inactive: false match_type: all

Post Search

active: true decaying_enabled: 0 force_inactive: false highlight_enabled: 0 highlight_excerpt: 0 highlight_tag: mark synonyms_editor_mode: simple synonyms:

# Defined sets ( equivalent synonyms).

Defined alternatives (explicit mappings).

m7 => m7100 f8 => f8000 6150 => f6150, f6150e, f6150sv

weighting: array ( 'post' => array ( 'post_title' => array ( 'weight' => 39, 'enabled' => true, ), 'post_content' => array ( 'weight' => 36, 'enabled' => true, ), 'post_excerpt' => array ( 'enabled' => true, 'weight' => 1, ), 'author_name' => array ( 'weight' => 20, 'enabled' => false, ), 'terms.post_tag.name' => array ( 'enabled' => true, 'weight' => 1, ), 'terms.category.name' => array ( 'enabled' => true, 'weight' => 1, ), 'terms.ep_custom_result.name' => array ( 'enabled' => true, 'weight' => 9999, 'fuzziness' => false, ), ), 'page' => array ( 'post_title' => array ( 'weight' => 63, 'enabled' => true, ), 'post_content' => array ( 'weight' => 60, 'enabled' => true, ), 'post_excerpt' => array ( 'enabled' => true, 'weight' => 1, ), 'author_name' => array ( 'weight' => 1, 'enabled' => false, ), 'terms.ep_custom_result.name' => array ( 'enabled' => true, 'weight' => 9999, 'fuzziness' => false, ), 'meta.indexable_content.value' => array ( 'enabled' => true, 'weight' => 60, ), ), 'news' => array ( 'post_title' => array ( 'weight' => 33, 'enabled' => true, ), 'post_content' => array ( 'weight' => 30, 'enabled' => true, ), 'post_excerpt' => array ( 'weight' => 1, 'enabled' => false, ), 'author_name' => array ( 'weight' => 15, 'enabled' => false, ), 'terms.ep_custom_result.name' => array ( 'enabled' => true, 'weight' => 9999, 'fuzziness' => false, ), ), 'product' => array ( 'post_title' => array ( 'enabled' => true, 'weight' => 100, ), 'post_content' => array ( 'enabled' => true, 'weight' => 90, ), 'post_excerpt' => array ( 'enabled' => true, 'weight' => 1, ), 'author_name' => array ( 'weight' => 1, 'enabled' => false, ), 'terms.ep_custom_result.name' => array ( 'enabled' => true, 'weight' => 9999, 'fuzziness' => false, ), 'meta.indexable_content.value' => array ( 'enabled' => true, 'weight' => 90, ), ), 'attachment' => array ( 'post_title' => array ( 'weight' => 1, 'enabled' => true, ), 'post_content' => array ( 'weight' => 1, 'enabled' => true, ), 'attachments.attachment.content' => array ( 'weight' => 1, 'enabled' => true, ), ), 'product-category' => array ( 'post_title' => array ( 'enabled' => true, 'weight' => 50, ), 'post_content' => array ( 'enabled' => true, 'weight' => 50, ), 'post_excerpt' => array ( 'weight' => 1, 'enabled' => false, ), 'author_name' => array ( 'weight' => 1, 'enabled' => false, ), 'terms.ep_custom_result.name' => array ( 'enabled' => true, 'weight' => 9999, 'fuzziness' => false, ), 'meta.indexable_content.value' => array ( 'enabled' => true, 'weight' => 50, ), ), 'cool_timeline' => array ( 'post_title' => array ( 'enabled' => true, 'weight' => 1, ), 'post_content' => array ( 'enabled' => true, 'weight' => 1, ), 'post_excerpt' => array ( 'weight' => 1, 'enabled' => false, ), 'author_name' => array ( 'weight' => 1, 'enabled' => false, ), 'terms.ep_custom_result.name' => array ( 'enabled' => true, 'weight' => 9999, 'fuzziness' => false, ), ), 'expandedcta' => array ( 'post_title' => array ( 'weight' => 1, 'enabled' => false, ), 'post_content' => array ( 'weight' => 1, 'enabled' => false, ), 'post_excerpt' => array ( 'weight' => 1, 'enabled' => false, ), 'author_name' => array ( 'weight' => 1, 'enabled' => false, ), 'terms.ep_custom_result.name' => array ( 'enabled' => true, 'weight' => 9999, 'fuzziness' => false, ), ), 'webinar' => array ( 'post_title' => array ( 'enabled' => true, 'weight' => 40, ), 'post_content' => array ( 'enabled' => true, 'weight' => 40, ), 'post_excerpt' => array ( 'weight' => 1, 'enabled' => false, ), 'author_name' => array ( 'weight' => 1, 'enabled' => false, ), 'terms.ep_custom_result.name' => array ( 'enabled' => true, 'weight' => 9999, 'fuzziness' => false, ), ), 'mec-events' => array ( 'post_title' => array ( 'enabled' => true, 'weight' => 40, ), 'post_content' => array ( 'enabled' => true, 'weight' => 40, ), 'post_excerpt' => array ( 'weight' => 1, 'enabled' => false, ), 'author_name' => array ( 'weight' => 1, 'enabled' => false, ), 'terms.post_tag.name' => array ( 'enabled' => true, 'weight' => 1, ), 'terms.ep_custom_result.name' => array ( 'enabled' => true, 'weight' => 9999, 'fuzziness' => false, ), ), )

Related Posts

active: true force_inactive: false

WPML integration

active: true force_inactive: false

Code of Conduct

  • [x] I agree to follow this project's Code of Conduct

gwhitehead avatar Dec 10 '25 17:12 gwhitehead

Hi @gwhitehead. A couple of questions:

  1. Did you try that in a setup that does not involve WPML?
  2. Can you share the link to that A12340 product with us, please?

PS.: You are using ElasticPress.io through our partnership with WP Engine. To expedite your support, feel free to open a ticket with WPE explaining your problem (and they can escalate that to us if needed) -- it is usually faster than relying on the support we offer here at GitHub.

felipeelia avatar Dec 12 '25 15:12 felipeelia

Hi agan Felipe, I am going to start a ticket within the WPE system to try to get this resolved. Thanks, Greg

gwhitehead avatar Dec 12 '25 19:12 gwhitehead

Hi @gwhitehead,

Since you have already opened a ticket with WPE, I am going to close this issue and continue all further communication in that ticket.

Regards, Burhan

burhandodhy avatar Dec 16 '25 07:12 burhandodhy