Jelle Roorda
Forum Replies Created
-
Forum: Plugins
In reply to: [Social Divi] Social Divi not compatible with latest Font Awesome versions?Hi @vpep!
I’m happy to let you know I was able to find some time to look at your issue. There was indeed a conflict with the latest version of Font Awesome plugin; they changed the name of their main plugin file. This conflicted with the Social Divi plugin since it wasn’t able to detect the activated Font Awesome plugin.
The Social Divi plugin has been updated to allow for both the previous versions and the new version.
Could you verify this for me by updating to the latest version (1.1.3) when it becomes available for you in the WordPress plugin repository?
Best regards,
JelleForum: Plugins
In reply to: [Social Divi] Social Divi not compatible with latest Font Awesome versions?Hi @vpep,
Good to hear you are enjoying the plugin.
I will try to find a gap in my schedule to see if I can debug the issue you mentioned.
Thanks in advance for your detailed feedback about the version numbers!
I will let you know when I have any updates on this.
Best regards,
JelleForum: Plugins
In reply to: [Social Divi] Tested in Latest WordPress BuildHi Waren,
Thanks for testing on the latest version.
I’ll update the repo as soon as I find some spare time!Regards,
JelleHi @gabelivan, thanks for your reply!
I re-downloaded the plugin, and the issue seems to be fixed (without enabling the json extension, which was disabled as you guessed).
I’ll enable the json extension just to make sure I won’t be experiencing any unnecessary errors in the future!
Thanks a bunch for your quick reply and resolution, really appreciated!
It was indeed the post type. After selecting all it works as it’s supposed to be.
This is not returning any rows either
As I mentioned in my first post, the searches are indeed displaying properly, the only problem is that the searches are not displayed ordered on relevance.
Because the following query always returns 0 rows:
SELECT DISTINCT ID, (MATCH(post_title) AGAINST ('*****' ) * 1 ) + (MATCH(post_content) AGAINST ('*****' ) * 1 ) AS score FROM wp_posts WHERE 1=1 AND MATCH (post_title,post_content) AGAINST ('*****' ) AND (post_status = 'publish' OR post_status = 'inherit') AND wp_posts.post_type IN ('post') ORDER BY score DESC
Replace ‘*****’ by any search term.
jelle-roorda.nl
You will be able to enter with
user: [moderated]
pass: [moderated]I checked, and I indeed have 3 indices, bsearch, bsearch_title and bsearch_content.
Something more like this probably.
I have tried running normal searches (without the plugin enabled) if that’s what you mean, and nothing really changes. The only visible change is the highlighting of the keywords in the results.
Not sure where to look for the full text index, but I’m still pretty sure it doesn’t exist.
How do I fix this?
That’s not really the way to do it stewagner,
Ajay is pointing you to the where filter.
You can use it like this:
function my_custom_posts_where($where) { // Edit the where part of the query, add the NOT IN part $where .= "AND wp_posts.ID NOT IN (3521, 3519) "; // Return the where part to the plugin return $where; } add_filter('bsearch_posts_where', 'my_custom_posts_where');
Although I’m not entirely sure the part I added to your query will fix it, this is the way to add parts to the query.
Oh and by the way, you write this code in your functions.php of your theme (if you are not using your own theme, use a child theme to make sure your overwrite will not be removed in the next update of your theme).
Hello Ajay,
Thanks for your quick reply.
As suggested I have installed Query Monitor, and ran the following query on my database:
SELECT DISTINCT ID, (MATCH(post_title) AGAINST ('test' ) * 1 ) + (MATCH(post_content) AGAINST ('test' ) * 1 ) AS score FROM wp_posts WHERE 1=1 AND MATCH (post_title,post_content) AGAINST ('test' ) AND (post_status = 'publish' OR post_status = 'inherit') AND wp_posts.post_type IN ('post') ORDER BY score DESC
I also used different search keywords, like: “testabcdefg”, “mind” or “mindmap”. This are all keywords that return results on the search page.
I’m always getting an empty dataset, on every query I run.
I assume the plugin gives every post a score of 0, and afterwards they probably get ordered on the time the posts were created.
I infer this from:
SELECT DISTINCT ID, 0 AS score FROM wp_posts WHERE 1=1 AND ( ((post_title LIKE '%test%') OR (post_content LIKE '%test%')) OR (post_title LIKE '%test%') OR (post_content LIKE '%test%') ) AND (post_status = 'publish' OR post_status = 'inherit') AND wp_posts.post_type IN ('post') ORDER BY post_date DESC
Seeing this query, another questions arises: why are you double checking for post_title and post_content?
Not sure where to go from here, since it seems the query is not working.
Kindly awaiting your reply,