Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › custom fields in main search box
- This topic has 25 replies, 2 voices, and was last updated 4 years, 3 months ago by
Ernest Marcinko.
-
AuthorPosts
-
January 25, 2022 at 11:43 am #36385
yaron10891
ParticipantI have a custom field called country.
if i select for example France from the drop down:
see image #1i get 33 results of posts that has this value in this custom field.
but it i put France in the search box i get only 7 and none of them are posts that has france in the country – they are post that has this value in the content
see image #2I use index table and this field is added in the list of custom field the search sould index
see image #3this issue happens also with other custom fields
January 25, 2022 at 8:56 pm #36399Ernest Marcinko
KeymasterHi!
Thank you very much for the details, it helped a lot.
I checked the configuration, and the “country” custom field was not selected in the index table options panel, so I added it: https://i.imgur.com/wLFZAfX.png
After re-indexing, the results appear to contain the missing items as well.January 27, 2022 at 2:31 pm #36430yaron10891
ParticipantYou cannot access this content.
January 28, 2022 at 10:45 am #36438Ernest Marcinko
KeymasterYou cannot access this content.
January 28, 2022 at 11:27 am #36447yaron10891
ParticipantYou cannot access this content.
January 31, 2022 at 2:11 pm #36485yaron10891
ParticipantYou cannot access this content.
January 31, 2022 at 3:15 pm #36492Ernest Marcinko
KeymasterHi,
Thank you for the details, I had to investigate this further on our local setups.
Seem like there was something not okay with the ACF label indexing, somehow only the values of the fields were insterted into the databsase. I have made a direct correction to the index table file, searching the fields by their labels should now yield at least the same amount of results for those queries.
I will include this fix in the upcoming release.
February 2, 2022 at 9:35 am #36506yaron10891
ParticipantYou cannot access this content.
February 2, 2022 at 11:21 am #36510Ernest Marcinko
KeymasterHi,
I tested again, but it seems to be all right on our ends regarding the “school” custom field: https://i.imgur.com/DR1nWvF.png
The partners field values are requested from ACF directly. It is possible, that the ones, which may not have any posts assigned to them may not be returned by ACF yet.
Another possibility is that ACF simply does not return those choices. It is notoriously hard to get object storage field values correctly via using their API, it is known to them as well.If you want, you can add temporary FTP details, and I will try to go through the relevant code, to see if there is any way to get the missing elements somehow programmatically.
February 2, 2022 at 12:44 pm #36515yaron10891
ParticipantYou cannot access this content.
February 2, 2022 at 2:44 pm #36523Ernest Marcinko
KeymasterYou cannot access this content.
February 8, 2022 at 2:59 pm #36589yaron10891
ParticipantYou cannot access this content.
February 9, 2022 at 11:11 am #36609Ernest Marcinko
KeymasterYou cannot access this content.
February 9, 2022 at 11:22 am #36611yaron10891
ParticipantYou cannot access this content.
February 14, 2022 at 4:31 pm #36732yaron10891
ParticipantYou cannot access this content.
-
AuthorPosts
- You must be logged in to reply to this topic.