用户注册



邮箱:

密码:

用户登录


邮箱:

密码:
记住登录一个月忘记密码?

发表随想


还能输入:200字
云代码 - php代码库

WordPress后台edit-tags.php里无限栏目分类实现

2014-10-30 作者: php源代码大全举报

[php]代码库

/**
 * Generate the table rows
 *
 * @since 3.1.0
 * @access protected
 */
function display_rows() {
    foreach ( $this->items as $item )
        $this->single_row( $item );
}
 
/**
 * Generates content for a single row of the table
 *
 * @since 3.1.0
 * @access protected
 *
 * @param object $item The current item
 */
function single_row( $item ) {
    static $row_class = '';
    $row_class = ( $row_class == '' ? ' class="alternate"' : '' );
 
    echo '<tr' . $row_class . '>';
    $this->single_row_columns( $item );
    echo '</tr>';
}
 
/**
 * Generates the columns for a single row of the table
 *
 * @since 3.1.0
 * @access protected
 *
 * @param object $item The current item
 */
function single_row_columns( $item ) {
    list( $columns, $hidden ) = $this->get_column_info();
 
    foreach ( $columns as $column_name => $column_display_name ) {
        $class = "class='$column_name column-$column_name'";
 
        $style = '';
        if ( in_array( $column_name, $hidden ) )
            $style = ' style="display:none;"';
 
        $attributes = "$class$style";
 
        if ( 'cb' == $column_name ) {
            echo '<th scope="row" class="check-column">';
            echo $this->column_cb( $item );
            echo '</th>';
        }
        elseif ( method_exists( $this, 'column_' . $column_name ) ) {
            echo "<td $attributes>";
            echo call_user_func( array( &$this, 'column_' . $column_name ), $item );
            echo "</td>";
        }
        else {
            echo "<td $attributes>";
            echo $this->column_default( $item, $column_name );
            echo "</td>";
        }
    }
}


网友评论    (发表评论)


发表评论:

评论须知:

  • 1、评论每次加2分,每天上限为30;
  • 2、请文明用语,共同创建干净的技术交流环境;
  • 3、若被发现提交非法信息,评论将会被删除,并且给予扣分处理,严重者给予封号处理;
  • 4、请勿发布广告信息或其他无关评论,否则将会删除评论并扣分,严重者给予封号处理。


扫码下载

加载中,请稍后...

输入口令后可复制整站源码

加载中,请稍后...