Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Some products dont show in search
- This topic has 13 replies, 2 voices, and was last updated 10 years, 6 months ago by
Enzo Nardo Di Maio.
-
AuthorPosts
-
November 9, 2015 at 12:43 pm #6574
Enzo Nardo Di Maio
ParticipantDear,
i have installed your plugin but some products dont show in search. Example:Cesarini Sartori Rossobastardo but if search Cesarini Sartori the ajax search show me only 2 products
Ruffino Chianti Superiore
Antinori only some products
this also for other some products.
How i can fix it?
i used table index.
Best Regards-
This topic was modified 10 years, 6 months ago by
Enzo Nardo Di Maio.
November 9, 2015 at 1:46 pm #6575Ernest Marcinko
KeymasterHi!
Looks like the translation ID for italian is missing from Cesarini Sartori Rossobastardo product. If I switch to english, I can see the result.
You can try 3 different solutions:
1. Solution
- Deactivate and Activate WPML again. This should generate the missing tranlsations.
- …then Re-create the Index Engine (Delete Index -> New index: http://i.imgur.com/PoFPNGg.png )
2. If 1. solution not working, then:
Open wp-content/plugins/ajax-search-pro/includes/etc/indextable.class.php file and go to line 908 – 926, where you should see this:
[php]private function langcode_post_id($post){
global $wpdb;$post_type = "post_" . $post->post_type;
$query = $wpdb->prepare("
SELECT language_code
FROM " . $wpdb->prefix . "icl_translations
WHERE
element_type = ‘%s’ AND
element_id = %d"
, $post_type, $post->ID);
$query_exec = $wpdb->get_row($query);if ( null !== $query_exec )
return $query_exec->language_code;return "";
}[/php]Change it to:
[php]private function langcode_post_id($post){
global $wpdb;
global $sitepress;$post_type = "post_" . $post->post_type;
$query = $wpdb->prepare("
SELECT language_code
FROM " . $wpdb->prefix . "icl_translations
WHERE
element_type = ‘%s’ AND
element_id = %d"
, $post_type, $post->ID);
$query_exec = $wpdb->get_row($query);if ( null !== $query_exec )
return $query_exec->language_code;if ( is_object($sitepress) && method_exists($sitepress, ‘get_default_language’) )
return $sitepress->get_default_language();return "";
}[/php]Then Re-create the Index Engine (Delete Index -> New index: http://i.imgur.com/PoFPNGg.png )
Let me know if any of this helps!
November 9, 2015 at 3:51 pm #6576Enzo Nardo Di Maio
ParticipantDear,
Dont work. Work only in EN website. I have insert new products Zenato and in EN website work, in IT site no.
it does not work with Regular Engine.
Best Regards.November 9, 2015 at 4:12 pm #6579Ernest Marcinko
KeymasterCan you please provide temporary FTP and Administrator access?
I would like to check the search configuration and debug the code for the problem.
November 9, 2015 at 5:52 pm #6585Enzo Nardo Di Maio
Participantyes, how i can send you in private?
November 9, 2015 at 8:24 pm #6587Ernest Marcinko
KeymasterYou can upload a .txt file or edit your first post in this thread for the details.
Both methods are safe and only visible to me and you.
November 10, 2015 at 10:17 pm #6605Enzo Nardo Di Maio
Participantok i wait your response.
November 11, 2015 at 8:31 am #6607Ernest Marcinko
KeymasterHi!
Thank you for the details. I have found the problem and fixed it in the search code. I’m including this fix in the upcoming update, so you don’t have to worry about it 🙂
November 11, 2015 at 9:45 am #6608Enzo Nardo Di Maio
ParticipantThanx =)
November 27, 2015 at 2:49 pm #6800Enzo Nardo Di Maio
ParticipantHi, with new version i have the same problem. How i can fix it?
Thanx.November 27, 2015 at 3:08 pm #6801Ernest Marcinko
KeymasterHi!
I’ve just tested and it seems all right to me. This version has the changes I’ve made on your site.
I have tried:
“Cesarini Sartori Rossobastardo” – got 1 result on both sites
“Ruffino Chianti Superiore” – no results on IT, because the DOCG category is excluded, and the product belongs there
“Antinori” – lots of products on both languagesNovember 27, 2015 at 3:14 pm #6802Enzo Nardo Di Maio
ParticipantYes, i have rewrite the article, try to items on VINI – VINI BIANCHI – ABRUZZO, example Fantini Farnese Casale Vecchio Cococciola. I noticed that the old products do not indexes,
November 27, 2015 at 3:20 pm #6803Ernest Marcinko
KeymasterThe “Fantini Farnese Casale Vecchio Cococciola” would return this I guess: http://www.enotecatuscia.it/prodotto/fantini-farnese-casale-vecchio-cococciola-terre-di-chieti-igt/
But if you check the product, it’s in the IGT category (https://i.imgur.com/09nNWyu.png), which is excluded on the Advanced Options panel: http://i.imgur.com/qwZLfAK.png
so the product is filtered out.November 27, 2015 at 3:23 pm #6804Enzo Nardo Di Maio
Participantoops 🙂
Thanx -
This topic was modified 10 years, 6 months ago by
-
AuthorPosts
- You must be logged in to reply to this topic.