Forums › Forums › Search & Filter Pro › Tags appearing in search results after filtering
- This topic has 23 replies, 2 voices, and was last updated 9 years, 6 months ago by
Anonymous.
-
Anonymous(Private) August 24, 2016 at 7:42 pm #55571
Is there a setting that affects this? I looked in the ‘display’ settings but couldn’t see anything. My search results at first load appear without tags, but if I filter for anything the updated results are displaying visual composer tags.
Thanks!
Trevor(Private) August 24, 2016 at 7:52 pm #55573Visual Composer often uses javascript to render shortcodes (I assume that’s what you mean by tags) and so a javascript error seems the likely first thing to look for. If you have Chrome, press ctrl+shift+I for the code inspector. One of the tabs for that is the console. Are any errors showing?
Anonymous(Private) September 1, 2016 at 11:11 pm #56398A interesting tidbit I just noticed which might be of interest โฆ I load my search page, the results are pre-loaded and look fine, no shortcodes displayed. If I filter for anything the results update and Visual Composer shortcodes appear. However if I then reload the whole page in my browser, the page reloads with the filtered results I had previously selected, but without Visual Composer shortcodes.
Trevor(Private) September 2, 2016 at 5:16 am #56406From what you say, this behavior is suggestive of Ajax loading of results. It also sounds, for some reason (maybe theme related, I am not sure) that the VC rendering javascript is not being reloaded after the S&F Ajax has done. In our FAQ Page, we have a small javascript snippet you could add to a page that would help you, maybe?
$(document).on("sf:ajaxfinish", ".searchandfilter", function(){ console.log("ajax complete"); //so load your lightbox or JS scripts here again });However, I do not know what function you would have to put on that commented line. Maybe WPBakery can advise you?
Anonymous(Private) September 9, 2016 at 1:53 pm #57096Oops, after further study ๐ I may have misstated the problem. Sorry ๐
I am using the shortcode to display results, and am using it to display results from a Custom Post Type. The CPT is part of WP-Customer Area, which enables userlevel-based viewing permissions on a page-by-page basis.
When I visit the URL with the search form on it, a set of results are loaded but instead of the excerpt they display parts of my menu. I guess this is probably related to viewing privileges. However if I filter for anything or search for any term the results update, but this time they DO contain the correct excerpt, along with the unwanted Visual Composer shortcakes.
So it seems like there are two separate issues going on.
The first part I’m not too worried about. If I could just have zero results pre-loaded when I visit the search page that would be fine. Is there a way I can disable the results that are “pre-loaded”?
The second part I would like to figure out a way to strip the tags.
Anonymous(Private) September 9, 2016 at 3:21 pm #57108On the results page? Everything seems to be laid out normally. It’s just a simple 2 row VC layout, with the search form on row 1 and the results shortcode on row 2.
If I click into the pages listed in the search results they are all laid out as expected.
-
AuthorPosts