Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

wp-admin table lists - like post list

Is there a API or something to build table lists in wp-admin?

With table lists I mean like the list of posts for example. It has columns, sorting, paging and so on.

Admin loop - the right way

When I create my loop I want it to look and feel like the core code, build it the right way.

No API? Give me an article

If there are no API like this, maybe point me to a great article about how to create it the best way possible.

share|improve this question
1  
There's no such API (as far as I know), but there are a couple of functions, filters and actions that'll allow you to create your own menu pages, object lists (like posts, media lists) etc. Google for: add_menu_page, add_submenu_page, register_column_headers, print_column_headers etc. These are a couple of things you should get along with. –  Rutwick Gangurde Oct 4 '11 at 6:10
add comment

1 Answer

up vote 1 down vote accepted

Yes, in version 3.1 WP_List_Table class was introduced and admin started to move to using it.

As of 3.2.x it currently is not officially declared to be stable API to be used by developers, but in practice it is usually more viable approach than building tables from scratch anyway.

On admin loops - admin side is not the easiest part of WP. It might be easier to retrieve itmes how you find convenient in your class extending WP_List_Table then trying to replicate admin mechanics precisely.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.