nick.thorley
Forum Replies Created
-
Forum: Plugins
In reply to: [ACF: Better Search] Not finding text within wysiwyg fieldIt does indeed work – many thanks. I hadnt realised that it was linked to the number of posts displayed – I presumed it was showing all and then the page I was expecting wasnt present, I presumed it hadnt found it.
Thanks for your help and maybe one for your faq’s section as I presume I wont be the last
Thanks again and sorry to be a pain
Forum: Plugins
In reply to: [ACF: Better Search] Not finding text within wysiwyg fieldthe sql is
SELECT DISTINCT SQL_CALC_FOUND_ROWS wp_posts.* FROM wp_posts INNER JOIN wp_postmeta AS a ON (a.post_id = wp_posts.ID) INNER JOIN wp_postmeta AS b ON ((b.meta_id = a.meta_id + @@auto_increment_increment) AND (b.post_id = wp_posts.ID)) INNER JOIN wp_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 (((c.post_name = b.meta_value) AND (a.meta_value LIKE ‘{df631c61fe2d2c73b07457ebd35534df4da3711fcc4ca0d1fac4aa78b7fa7e2b}power{df631c61fe2d2c73b07457ebd35534df4da3711fcc4ca0d1fac4aa78b7fa7e2b}’)) OR ((wp_posts.post_title LIKE ‘{df631c61fe2d2c73b07457ebd35534df4da3711fcc4ca0d1fac4aa78b7fa7e2b}power{df631c61fe2d2c73b07457ebd35534df4da3711fcc4ca0d1fac4aa78b7fa7e2b}’) OR (wp_posts.post_content LIKE ‘{df631c61fe2d2c73b07457ebd35534df4da3711fcc4ca0d1fac4aa78b7fa7e2b}power{df631c61fe2d2c73b07457ebd35534df4da3711fcc4ca0d1fac4aa78b7fa7e2b}’) OR (wp_posts.post_excerpt LIKE ‘{df631c61fe2d2c73b07457ebd35534df4da3711fcc4ca0d1fac4aa78b7fa7e2b}power{df631c61fe2d2c73b07457ebd35534df4da3711fcc4ca0d1fac4aa78b7fa7e2b}’))) AND wp_posts.post_type IN (‘post’, ‘page’, ‘attachment’, ‘case_study_item’, ‘service_item’, ‘product_item’, ‘staff_member_item’, ‘case_study_promotion’, ‘careers_item’) AND (wp_posts.post_status = ‘publish’ OR wp_posts.post_status = ‘acf-disabled’) ORDER BY wp_posts.post_title LIKE ‘{df631c61fe2d2c73b07457ebd35534df4da3711fcc4ca0d1fac4aa78b7fa7e2b}power{df631c61fe2d2c73b07457ebd35534df4da3711fcc4ca0d1fac4aa78b7fa7e2b}’ DESC, wp_posts.post_date DESC LIMIT 0, 10
Forum: Plugins
In reply to: [ACF: Better Search] Not finding text within wysiwyg fieldIts higher in the post 165
Forum: Plugins
In reply to: [ACF: Better Search] Not finding text within wysiwyg fielddatabase dump https://we.tl/t-4SumCe583A
Forum: Plugins
In reply to: [ACF: Better Search] Not finding text within wysiwyg fieldThis is the database screenshot
https://we.tl/t-smzJdWSBUbForum: Plugins
In reply to: [ACF: Better Search] Not finding text within wysiwyg fieldApologies – i did send a mail straight back but neglected to notice it was a no reply address.
Forum: Plugins
In reply to: [ACF: Better Search] Not finding text within wysiwyg fieldForum: Plugins
In reply to: [ACF: Better Search] Not finding text within wysiwyg fieldI emailed in screenshots but I dont think they may have reached you. please can you confirm how I can get them to you directly?
Forum: Plugins
In reply to: [ACF: Better Search] Not finding text within wysiwyg fieldI wondered if you have an update on this please, what may be wrong?
Nick
Forum: Plugins
In reply to: [ACF: Better Search] Not finding text within wysiwyg fieldThe other thing I forgot to mention is that the field concerned is stored within the acf repeater field which I have seen others have issues with. Not sure if thats significant.
Forum: Plugins
In reply to: [ACF: Better Search] Not finding text within wysiwyg fieldThanks for the reply – the sql, id of the post and the acf / better search versions are below
SELECT DISTINCT SQL_CALC_FOUND_ROWS wp_posts.* FROM wp_posts INNER JOIN wp_postmeta AS a ON (a.post_id = wp_posts.ID) INNER JOIN wp_postmeta AS b ON ((b.meta_id = a.meta_id + @@auto_increment_increment) AND (b.post_id = wp_posts.ID)) INNER JOIN wp_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 (((c.post_name = b.meta_value) AND (a.meta_value LIKE '{f4af6f01e3a96fea4b9009f6269b3925b1aad962543dd43060db49e864edc03c}power{f4af6f01e3a96fea4b9009f6269b3925b1aad962543dd43060db49e864edc03c}')) OR ((wp_posts.post_title LIKE '{f4af6f01e3a96fea4b9009f6269b3925b1aad962543dd43060db49e864edc03c}power{f4af6f01e3a96fea4b9009f6269b3925b1aad962543dd43060db49e864edc03c}') OR (wp_posts.post_content LIKE '{f4af6f01e3a96fea4b9009f6269b3925b1aad962543dd43060db49e864edc03c}power{f4af6f01e3a96fea4b9009f6269b3925b1aad962543dd43060db49e864edc03c}') OR (wp_posts.post_excerpt LIKE '{f4af6f01e3a96fea4b9009f6269b3925b1aad962543dd43060db49e864edc03c}power{f4af6f01e3a96fea4b9009f6269b3925b1aad962543dd43060db49e864edc03c}'))) AND wp_posts.post_type IN ('post', 'page', 'attachment', 'case_study_item', 'service_item', 'product_item', 'staff_member_item', 'case_study_promotion', 'careers_item') AND (wp_posts.post_status = 'publish' OR wp_posts.post_status = 'acf-disabled' OR wp_posts.post_author = 1 AND wp_posts.post_status = 'private') ORDER BY wp_posts.post_title LIKE '{f4af6f01e3a96fea4b9009f6269b3925b1aad962543dd43060db49e864edc03c}power{f4af6f01e3a96fea4b9009f6269b3925b1aad962543dd43060db49e864edc03c}' DESC, wp_posts.post_date DESC LIMIT 0, 10 the ID is 165
acf version Version 5.7.12
better search Version 3.1.2- This reply was modified 5 years, 1 month ago by Jan Dembowski.
- This reply was modified 5 years, 1 month ago by Jan Dembowski.
Forum: Themes and Templates
In reply to: creating a custom post searchThe search form is below. The form is contained within a wordpress page which has the url blog/page-project/
However when i hit search I am directed to the page url below – where project-2 is a custom post type rather than a page. I simply want the search to return to the same page.
/project/project-2/?contractperiod=sg&post_type=project&searchsubmit=Search
<form id=”searchform” action=”” method=”get”>
<input id=”contractperiod” maxlength=”6″ name=”contractperiod” size=”6″ type=”text” value=”” class=”txt” />
<input name=”post_type” type=”hidden” value=”project” />
<input id=”searchsubmit” name=”searchsubmit” class=”btn” type=”submit” value=”Search” />
</form>Thanks
Nick