Linux 软件免费装

Boone's Sortable Columns

开发者 boonebgorges
更新时间 2011年5月27日 08:19
捐献地址: 去捐款
PHP版本: WordPress 3.1 及以上
WordPress版本: WordPress 3.2-beta

标签

columns custom post types tables

下载

1.1 1.0

详情介绍:

Here's how I recommend using the class.
  1. Either activate this plugin, or include the class in your own plugin file.
  2. When you start to render the page with the post list, define some columns and then instantiate the class: $cols = array( array( 'name' => 'restaurant_name', 'title' => 'Restaurant Name', 'css_class' => 'restaurant-name', 'is_default' => true ), array( 'name' => 'cuisine_type', 'title' => 'Cuisine Type', 'css_class' => 'cuisine-type', 'default_order' => 'desc' ) ); $sortable = new BBG_CPT_Sort( $cols );
  3. As you render your table, you can use all sorts of fun methods to create column headers. Example: `
have_columns() ) : ?> have_columns() ) : $sortable->the_column() ?> the_column_title() ?> ... `

安装:

Two choices:
  1. Install from the plugins repository and activate for use in your theme or
  2. Copy the BBG_CPT_Sort class into your own plugin/theme and require it manually.

更新日志:

1.1 1.0