Forums › Forums › Search & Filter Pro › Getting highest-count tags to stay on top for the search results?
Tagged: tags count
- This topic has 4 replies, 2 voices, and was last updated 5 years, 4 months ago by
Trevor.
-
Anonymous(Private) September 30, 2019 at 6:18 pm #222409
Love this plug-in!
I’m building a system where cafe diners can select their food based on tags: https://www.therefectorycafe.com/tags/
The initial search page is perfect – the tags are listed with highest count at the top.
However, my issue is that in the search results, it seems random.How can I keep the tags with the highest count on top for the search results?
Thanks!
Trevor(Private) October 1, 2019 at 10:06 am #222442One thing you might want to consider is making those tags more like a tag cloud in the form, using custom CSS like this:
#search-filter-form-9474 .sf-field-tag input { display: none; } #search-filter-form-9474 .sf-field-tag label { text-align: center; line-height: 1.4em; border: 1px solid #666; border-radius: 3px; padding: 3px 5px !important; text-indent: 0; } #search-filter-form-9474 .sf-field-tag label:hover { cursor: pointer; } #search-filter-form-9474 .sf-field-tag > ul > li { display: inline-block; margin-left: 5px; margin-bottom: 10px; } #search-filter-form-9474 .sf-field-tag > ul { margin-left: -5px; } #search-filter-form-9474 .sf-field-tag > ul > li.sf-option-active label { background-color: #7DA85B; color: #fff; } #search-filter-form-9474 .sf-field-tag .sf-count { padding-right: 0; }
The new code would make it look like this in an example search:
https://www.screencast.com/t/78obilCRbV
And what it looked like before:
Anonymous(Private) October 1, 2019 at 1:05 pm #222481Wow! Just wow. Amazing!
What a huge help – it looks AWESOME!!!! Thanks Trevor.Really appreciate you going out of your way like this – you didn’t have to write custom CSS code for me – you could have ended your reply after the first sentence.
Have an awesome week!!
-
AuthorPosts