Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Inconsistant pagination
This topic contains 6 replies, has 2 voices, and was last updated by benchernett 5 years, 3 months ago.
- AuthorPosts
- February 12, 2018 at 1:02 pm #16748
Pagination is ignored when using a filter for isotropic results.
Also the Rows count option in Isotropic Results tab seems to get twice the number of rows entered. But sometimes sometimes uses that number as the per page.
i.e. Enter 2 for Row count. It will show 4 rows of 3 results with pagination. But sometimes it will only show 2 results with paginationFebruary 12, 2018 at 1:28 pm #16752Hi,
It is because you use the following custom CSS:
.asp_isotopic_item { padding: 15px !important; width: 33.3333% !important; position: static !important; height: auto !important; background-image: none !important; background-color: transparent !important; }
This changes the item width to 33% and the calculation for the isotope rows count uses the value that is defined under the plugin Theme Options -> Isotopic results panel: https://i.imgur.com/YQLvDP3.png
Since this is a different value, the calculation comes out incorrect.Instead of forcing the width, I recommend using a higher width value, like 400px or 500px on the back-end, and the isotope script will try to maintain that, with the correct rows count.
Best,
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
February 12, 2018 at 2:02 pm #16754Thanks for the quick response.
So is there no way of have width in percent?Could you clarify what the Row count option does?
Thanks
February 12, 2018 at 2:08 pm #16755Hi,
Currently there is no way to have a percentage witdth with correct rows count, but there will be in the upcoming release, as we update the script to calculate based on visible item values in stead of the defined ones. The item width input will also be changed to accept a percentage value as well.
The rows count simply indicates how many rows of items there should be before starting the pagination. The problem here is only the percentage width, as the calculation uses the initially defined pixel width. It will display the items fine, but the rows count will be incorrect.
Best,
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
February 12, 2018 at 2:12 pm #16756Ok Thanks.
Do you have a timeline on when that might be released?
Could you point me at the file(s) responsible? Maybe I can add a temporary fix now.
Thanks
February 12, 2018 at 2:24 pm #16757It should be out later on this week.
Yes, actually it might be possible to fix temporarily right now.
1. You will have to change the script source to the ‘Non-minified’ version here: https://i.imgur.com/vtkmYUJ.png
2. Then open up the \wp-content\plugins\ajax-search-pro\js\nomin\jquery.ajaxsearchpro.js file via FTP
3. Look for the function calculateIsotopeRows around lines 2476-2509: https://gist.github.com/anag0/a69842d7fc50af615dea6c601eabc7fa
4. Once you found it, replace that whole function with this modified one: https://gist.github.com/anag0/081449d056b182377c4263f8a695f0dfSave the file, clear your site cache, minify cache etc.. This is not the finalized solution though, but it may actually do the trick.
Best,
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
February 12, 2018 at 6:32 pm #16764That almost worked great!
I have three different searches on the page for three different custom post types. Two of the searches are hidden until the user clicks a button. As the results of these are hidden it was getting a width of 0. If I resized the browser it would recalculate and look correct. So I added the number of columns in manually and it is working now.
I guess this would be fixed in the release version if I was able to enter the width of 33.3333%.
Ideally I’d be able to say add
Desktop – 4 rows of 3 columns
Tablet – 3 rows of 2 columns
Mobile – 4 rows of 1 columnMaybe in a future release 🙂
Thanks for all the help
- AuthorPosts
You must be logged in to reply to this topic.