Support Forums

The forums are closed and will be removed when we launch our new site.

Looking for support? You can access the support system via your account.

Forums Forums Search & Filter Pro Pagination and FoundationPress

Viewing 8 posts - 1 through 8 (of 8 total)
  • Steven
    #19778

    I’m using a customized version of the FoundationPress WP theme. I’ve noticed for quite a while that my pagination hasn’t been working, and have assumed for a long time that it was something going on with the theme. After digging deeper, I think I’m running into problems with setting the correct Results and Pagination selectors.

    For Results I have: .pagination-centered
    For Pagination I have: .pagination a

    In a private message I’ll share a link to a development preview for the site. I feel like I’m using the correct selectors, but the pagination is not behaving properly:

    At first the pagination links weren’t doing anything when I would click on them. Then after tweaking with those selector options in the search/filter I was able to get the links to redirect the url to “…/page/2”, but the content wouldn’t change at all.

    Now, after changing my selectors to the current ones listed above, the pagination link for ‘page 2’ will become an “active” class, which it wouldn’t do before, but it still doesn’t load the rest of the results…

    Steven
    #19779
    This reply has been marked as private.
    Steven
    #19822

    Here’s a gist with some relevant (hopefully) code:

    https://gist.github.com/swthate/edfb3eb373df6d4123a0

    Trisha Miller
    #19885

    OK if I’m understanding everything you’ve correctly, including the info above where you posted this:

    For Results I have: .pagination-centered
    For Pagination I have: .pagination a

    You’ll need to be sure the actual class of the DIV that holds the pagination links matches what you have for your Pagination settings in the filter (currently you have it set to .pagination a, which is the default for this search/filter plugin)……Foundation Theme probably has the class selector buried in the function called ‘foundationpress_pagination’ – if that function didn’t exist, it would default to the WP standard pagination which uses a class of ‘post-previous’ and ‘post-next’…..so you just need to look at your source code for the pagination links and see what class Foundation is using for the DIV that surrounds those page links, then put that class in place of .pagination a into the box in the plugin settings…..remember the ‘a’ following the class is important, that targets the actual link itself.

    What you have above for “Results”, normally in the plugin settings you only fill that in if you’re using a specific template file for results, so a “class” doesn’t go there, a template name does.

    Ross Moderator
    #19986

    Hi Steven

    It does look like your pagination is now working, and your searches (if you check the network activity using firebug you will see new pages are loaded in the background.

    It seems as though your results container is wrong through.

    You results container must contain both your results and your pagination.

    The closest thing I could see on your page to a results container is:

    .large-12.column

    But this might target other areas on your site you do not want.

    What you have in your markup is something like:

    <div class="row">
    
    	<div class="large-12 column">
    
    		<ul class="large-block-grid-4 medium-block-grid-2 text-center">

    On this “row”. you need to add an ID like

    <div class="row" id="search-filter-results-container">
    
    	<div class="large-12 column">
    
    		<ul class="large-block-grid-4 medium-block-grid-2 text-center">

    Then in the settings your results container would be #search-filter-results-container – this should also allow your pagination to work.

    Thanks

    Ross Moderator
    #19987

    PS your pagination selector seems correct, so don’t change this.

    Thanks

    Steven
    #20103

    Thank you Ross,

    That makes a lot of sense, and it’s working now!

    Steven
    #21727

    Update:

    I think the only reason that was working for me, was because my slug was set to veterans. I’m having the same problem on my organizations page. When the slug is set to either veterans or organizations, pagination works. However, the archive page then uses the results-*.php template, not the correct results-*.php template I want results directed to.

    When I remove the slug, and the page uses the correct archive-*.php template, pagination stops working, regardless if Ajax is enabled or disabled.

Viewing 8 posts - 1 through 8 (of 8 total)

The forum ‘Search & Filter Pro’ is closed to new topics and replies.