Forums › Forums › Search & Filter Pro › Display Results
- This topic has 16 replies, 2 voices, and was last updated 3 years, 9 months ago by Trevor.
-
Trevor(Private) September 23, 2020 at 3:19 pm #260478
In the template file for that page, you need to find where it calls the pagination. The chances are it is a call to an external function. You will need to edit the template file (using a child theme copy of the file for safety) and remove that pagination function and replace it.
For example, the WP-PageNavi plugin is a very popular pagination plugin, and if you have that installed, the code might be something like I show here:
WP-PageNavi can also add page xx of xxx.
Similarly, to add the number of results code, assuming the results array is named $query:
Found <?php echo $query->found_posts; ?> Results
Editing your template files would be outside the scope of our support, so you would need the help of the theme author or a third party coder.
Trevor(Private) February 1, 2021 at 3:59 pm #274830You would need to set the
minDate
andmaxDate
of the datepicker, oryearRange
if that is all you need to do.This would require you to add some additional JavaScript to the page.
This post shows some other options being set in this way:
https://support.searchandfilter.com/forums/topic/search-by-date-for-ancient-documents/#post-184587
I am sure you can modify what is there.
Anonymous(Private) February 1, 2021 at 6:02 pm #274875Hi, Trevor
Can You say where I need to put that code, in which file?
In your example there is fixed values for yearRange and defaultDate, but I want to set date of today like min date, and don’t allow to select earlier. And for “to” date don’t allow to select earlier than selected in “from” field. Is it possible, have you an example like it?jQuery(document).on(“sf:init”, “.searchandfilter”, function(){
jQuery(“#search-filter-form-108 .sf-datepicker”).datepicker(‘option’,{
yearRange: ‘1908:1908’,
defaultDate: ‘1/1/1908’,
changeYear: false
});
});in this code 108 is id of filter?
Can you say all list of keys and arguments for datepicker option, or can you send me link of more detailed documentation? -
AuthorPosts