Tedmanders
Forum Replies Created
-
Forum: Plugins
In reply to: [ACF: Better Search] No results are found in ACF fieldsI have updated the plugin and modified the code. The search is working well now!
Below a screenshot of the result from the sql command in phpmyadmin:
Thank you so much for your help. I appreciate it!
Forum: Plugins
In reply to: [ACF: Better Search] No results are found in ACF fieldsI have installed version 3.0.1 and this one seems to be working. The search results now show my CPT content, so that’s great.
The search query is takes quite long though, atleast 5 seconds. Are there any security risks by using the older version?Thank you for your help.
Forum: Plugins
In reply to: [ACF: Better Search] No results are found in ACF fieldsI have checked term_taxonomy_id IN (2) in the database and it seems to be the currently selected language that is added by the plugin ‘Polylang’
Each language seems to have it’s own term ID.Forum: Plugins
In reply to: [ACF: Better Search] No results are found in ACF fieldsHow do you mean?
I search in the standard WordPress search form for a term in an ACF field.
The post with the field can be in a (sub)category.For example I type ‘volvo’ in the form. Which is a name in the title field of a post.
I wonder why this taxonomy id is added to the SQL..
Do you know why this gets added to the query?Forum: Plugins
In reply to: [ACF: Better Search] No results are found in ACF fieldsI don’t have slug defined in the register post type so I guess it defaults to the post type name ‘artikelen’ ?
I do have the following rewrite defined to edit the url to display categories and children of categories:
`’rewrite’ => array(
‘slug’ => ‘producten/%category%’, ‘with_front’ => true,
),’%category% get’s replaced later using a hook in my functions file. I’m not sure if it’s relevant to the problem, but maybe the url customizing has an effect on the search.
Thank you for your help.
- This reply was modified 6 years ago by Tedmanders. Reason: spelling, clarity
Forum: Plugins
In reply to: [ACF: Better Search] No results are found in ACF fieldsAnd the query result of:
SELECT * FROM abctrac_postmeta WHERE post_id = 541Forum: Plugins
In reply to: [ACF: Better Search] No results are found in ACF fieldsThis is the SQL query of the search (I added the code you posted in other threads for functions/search.php)
SELECT DISTINCT SQL_CALC_FOUND_ROWS abctrac_posts.* FROM abctrac_posts LEFT JOIN abctrac_term_relationships ON (abctrac_posts.ID = abctrac_term_relationships.object_id) INNER JOIN abctrac_postmeta AS a ON (a.post_id = abctrac_posts.ID) INNER JOIN abctrac_postmeta AS b ON ((b.meta_id = a.meta_id + @@auto_increment_increment) AND (b.post_id = abctrac_posts.ID)) INNER JOIN abctrac_posts AS c ON ((c.post_type = ‘acf-field’) AND ((c.post_content LIKE ‘%:”text”%’) OR (c.post_content LIKE ‘%:”textarea”%’) OR (c.post_content LIKE ‘%:”wysiwyg”%’))) WHERE 1=1 AND (
abctrac_term_relationships.term_taxonomy_id IN (2)
)AND (((c.post_name = b.meta_value) AND (a.meta_value LIKE ‘%volvo%’)) OR ((abctrac_posts.post_title LIKE ‘%volvo%’) OR (abctrac_posts.post_content LIKE ‘%volvo%’) OR (abctrac_posts.post_excerpt LIKE ‘%volvo%’))) AND abctrac_posts.post_type IN (‘post’, ‘page’, ‘attachment’, ‘artikelen’) AND (abctrac_posts.post_status = ‘publish’ OR abctrac_posts.post_status = ‘acf-disabled’) GROUP BY abctrac_posts.ID ORDER BY abctrac_posts.post_title LIKE ‘{b050309699cde54c19f3db5d799109dadcc74f4b57f8f0b694228cacbe41675e}volvo{b050309699cde54c19f3db5d799109dadcc74f4b57f8f0b694228cacbe41675e}’ DESC, abctrac_posts.post_date DESC LIMIT 0, 10- This reply was modified 6 years ago by Tedmanders. Reason: spelling
Hi dcooney,
Thank you for clarifying what happens.
I understand the problem and will try to fix it another way.
I’ll check out the link.Cheers
Forum: Plugins
In reply to: [WooCommerce] Add quantity box to upsell productsHow could I limit it to only upsell products?
Thanks for your response.Forum: Plugins
In reply to: [WooCommerce] Add quantity box to upsell productsThank you for your reply.
This looks like the thing i’m looking for.
Will this snippet be useable for upsell products when you have updated it?Thanks again.
Forum: Fixing WordPress
In reply to: Widget getting placed outside of sidebar areaI found out through the themes forum what the problem was. So just sharing for people that also get this problem.
The widgets I used had a title field in the admin area. I left these empty because I didn’t want any text inside of them. It seemed that these empty fields somehow closed the sidebar div and put all the other widgets outside of it. So all I had to do to fix them was put something in the title field. I placed a ‘space’ inside it and it was fixed.
Hope this helps, thanks for the replies people.
Forum: Fixing WordPress
In reply to: Widget getting placed outside of sidebar areaSorry the URL is: https://www.saplingmedia.nl/test/Ericossie/
You can see that the ‘social’ block is moved out of the widget sidebar.
I will try to switch to the default theme and contact the theme support.
Thanks for your replies so far!