• Resolved dgracey

    (@dgracey)


    I am struggling to find how to add pagination. I added an “amount” and set pagination to yes. Is there something different I need to do to limit the number of authors displayed on one page and add pagination?

    The page I need help with: [log in to see the link]

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author WPKube

    (@wpkube)

    Hi @dgracey

    The simplest example is:

    [authors_list pagination="yes" amount="4"]

    That would show 4 authors per page.

    Can you send over the full shortcode you’re using?

    By the way, it won’t work seamlessly with the region filters you have. The pagination in the plugin is PHP based and the region filters you have are JS based. The region filters will only affect the X amount of authors shown on that specific page. So you’ll also need JS based pagination, and both the filters and pagination need to work together so when you change the region it needs to reinitiate the pagination to be based only the items that apply to that region.

    Thread Starter dgracey

    (@dgracey)

    Thank you. Here is the shortcode I was using:
    [authors_list style=”1″ columns=”4″ pagination=”yes” amount=”1″ show_count=”no” show_bio=”yes” roles=”thc_member” authors_only=”no” after_bio=”{al:mepr_bio}” before_bio=”{al:mepr_county}”]

    I decided to move away from pagination for the time being in favor of having the filter until our membership numbers requires that change. For some reason, the pagination does not work and neither does the 4 column setting. I can follow on that in another support post if needed.

    • This reply was modified 3 years, 4 months ago by dgracey.
    Plugin Author WPKube

    (@wpkube)

    Hi @dgracey

    Since the columns don’t work either it sounds like the quotes are wrong, WordPress only recognizes the plain " for shortcode attributes.

    Can you try copy/pasting this:

    [authors_list style="1" columns="4" pagination="yes" amount="1" show_count="no" show_bio="yes" roles="thc_member" authors_only="no" after_bio="{al:mepr_bio}" before_bio="{al:mepr_county}"]

    When you put quotes " here on the forum they get changed to and but looking at the code you sent there’s 3 types, other than the 2 mentioned there’s as well which further points me in that quotes issue.

    Thread Starter dgracey

    (@dgracey)

    For some reason, the filter developer added code to restrict the columns to three. I was able to see the columns change using your shortcode after I removed their CSS. Thank you!

    Plugin Author WPKube

    (@wpkube)

    You’re welcome.

    The developer probably restricted it because of the way the columns system work in the plugin. All items except the last in the row have a right margin. If it’s 3 columns every 3rd item doesn’t have the margin. So if some items are hidden (the region filters) those go out of sync and can end up with weird layout (for example 2nd item having no right margin instead of the 3rd).

    Won’t be an issue for much longer, we’ll soon be switching the columns system over to a flex approach instead of a float, in which case the issue won’t happen.

    Thread Starter dgracey

    (@dgracey)

    Very good to know. Thank you! I will be adding flex on my end in the meantime to further control the column count and width on different screen sizes. Looking forward to that update!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Add pagination’ is closed to new replies.