display_rows example


    protected function extra_tablenav( $which ) {}

    /** * Generates the tbody element for the list table. * * @since 3.1.0 */
    public function display_rows_or_placeholder() {
        if ( $this->has_items() ) {
            $this->display_rows();
        } else {
            echo '<tr class="no-items"><td class="colspanchange" colspan="' . $this->get_column_count() . '">';
            $this->no_items();
            echo '</td></tr>';
        }
    }

    /** * Generates the table rows. * * @since 3.1.0 */
if ( is_post_type_hierarchical( $wp_list_table->screen->post_type ) ) {
        $request_post = array( get_post( $_POST['post_ID'] ) );
        $parent       = $request_post[0]->post_parent;

        while ( $parent > 0 ) {
            $parent_post = get_post( $parent );
            $parent      = $parent_post->post_parent;
            $level++;
        }
    }

    $wp_list_table->display_rows( array( get_post( $_POST['post_ID'] ) )$level );

    wp_die();
}

/** * Handles Quick Edit saving for a term via AJAX. * * @since 3.1.0 */
function wp_ajax_inline_save_tax() {
    check_ajax_referer( 'taxinlineeditnonce', '_inline_edit' );

    
/** * @return string[] Array of column titles keyed by their column name. */
    public function get_columns() {
        return array();
    }

    /** */
    public function display_rows_or_placeholder() {
        if ( $this->has_items() ) {
            $this->display_rows();
        } else {
            echo '<div class="no-items">';
            $this->no_items();
            echo '</div>';
        }
    }

    /** */
    public function display_rows() {
        $themes = $this->items;

        
Home | Imprint | This part of the site doesn't use cookies.