Definition:
function manage_columns_prefs( $page ) {}
Parameters
- unknown_type $page
Source code
function manage_columns_prefs( $page ) { $columns = get_column_headers( $page ); $hidden = get_hidden_columns( $page ); $special = array('_title', 'cb', 'comment', 'media', 'name', 'title', 'username'); foreach ( $columns as $column => $title ) { // Can't hide these or they are special if ( in_array( $column, $special ) ) continue; if ( empty( $title ) ) continue; if ( 'comments' == $column ) $title = __( 'Comments' ); $id = "$column-hide"; echo '<label for="' . $id . '">'; echo '<input class="hide-column-tog" name="' . $id . '" type="checkbox" id="' . $id . '" value="' . $column . '"' . (! in_array($column, $hidden) ? ' checked="checked"' : '') . ' />'; echo "$title</label>\n"; } }
2321
No comments yet... Be the first to leave a reply!