WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm using the list-category-post plugin - is it possible to display the list of posts in a table?

I want to have a dynamic table showing all the posts in a category, so a user can search the table and select a column to sort by.

Is this possible?


share|improve this question

closed as too localized by Wyck, kaiser, Chip Bennett, Brady Apr 2 '12 at 14:28

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

Welcome to Wordpress Answers! If the answer below worked for you, consider clicking the checkmark to mark it as Accepted. – hairboat Jan 31 '12 at 20:39

This plugin does allow theming. Check out the "Other Notes" tab in the plugin page. As far as making it sortable, your path of least resistance is to use javascript. Here's a jQuery plugin that will do (almost) all the work for you. Hope that helps!


share|improve this answer
Thank you for the response. So I can use the template theming to show the list in a table rather than a list? – mary hughes Jan 30 '12 at 18:43
Yes, absolutely! As noted on that "Other notes" page, "You can use the included template as an example to start. It's in the plugin's template folder under the name default.php." – Matthew Boynes Jan 30 '12 at 18:55
Thanks for your help. I've got the posts displaying in a table, do you have any tips on how to add a header row? I am completely new to php. I've copied the template code I am using below in another comment. – mary hughes Feb 5 '12 at 21:09
//'starting' tag: $lcp_display_output .= '<table class="lcp_catlist">'; /*** Posts loop. */ foreach ($this->catlist->get_categories_posts() as $single): //Start a row for each post: $lcp_display_output .= "<tr><td>"; //Show the title and link to the post: $lcp_display_output .= $this->get_post_title($single, 'td'); $lcp_display_output .= "<td>"; //Custom fields: $lcp_display_output .= $this->get_custom_fields($this->params['customfield_display'], $single->ID); $lcp_display_output .= "</td>"; – mary hughes Feb 5 '12 at 21:10

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