• I developed a plugin to be running on the admin side, and it has been working great, except for one thing.

    I am looking to implement pagination on the records viewed, and I have a feeling that wordpress has a class or something that will automatically generate the filter forms, like what you see when you view the posts.

    Is there a way for me to reuse this?

Viewing 5 replies - 1 through 5 (of 5 total)
  • I have a feeling that wordpress has a class or something that will automatically generate the filter forms, like what you see when you view the posts.

    I don’t have any idea what you’re referring to there, but for creating pagination links there is paginate_links.

    I’ve also moved the thread from the installation forum, as i can’t see how this relates to installing WordPress.

    Thread Starter dotslashbin

    (@dotslashbin)

    this is not what I was looking for. Here’s some clarification.

    On the admin side of the CMS, you click on “posts” from the posts menu. By then you’ll notice that there is list of all posts, with a table filter above.

    What I want to do is to reuse that filter. The filter contains search, dropdowns, and etc…

    Perhaps the question was a little misleading then, pagination refers to splitting results across pages, ie. paging..

    The filters you see are specifically for posts, unless you’re displaying posts they will be of little use to your plugin.

    That said, you can see how those filters are created by looking directly to the source, which you can find here.

    http://core.trac.wordpress.org/browser/tags/3.0.1/wp-admin/edit.php#L249

    Sorting a list of results based on a filter is fairly simple, but without knowing what you’re trying to sort and how you’re grabbing that data it’s not really possible to provide an example.

    Thread Starter dotslashbin

    (@dotslashbin)

    The filters you see are specifically for posts, unless you’re displaying posts they will be of little use to your plugin.

    That said, you can see how those filters are created by looking directly to the source, which you can find here.

    hehe Yeah, I think my question was indeed misleading, although I am sure that you got what I meant.

    I was looking for some library that I can use to generate the filters. Is there such thing?

    A library, like a set of functions? Not for those particular filters, as can be seen by the source code linked above.

    Filters are relatively easy to write and i’m not sure a library should exist for something that’s only used in one or two places.

    If you can provide an example(using a pastebin please) of what you’re trying to filter i’ll do what i can to provide you with an example.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Implementing pagination on a custom made plugin’ is closed to new replies.