manage_page->search_result; // we didn't set a gallery or a pagination $act_gid = 0; $_GET['paged'] = 1; $page_links = false; } else { // GET variables $act_gid = $ngg->manage_page->gid; // Load the gallery metadata $gallery = $nggdb->find_gallery($act_gid); if (!$gallery) { nggGallery::show_error(__('Gallery not found.', 'nggallery')); return; } // Check if you have the correct capability if (!nggAdmin::can_manage_this_gallery($gallery->author)) { nggGallery::show_error(__('Sorry, you have no access here', 'nggallery')); return; } // look for pagination $_GET['paged'] = isset($_GET['paged']) && ($_GET['paged'] > 0) ? absint($_GET['paged']) : 1; $start = ( $_GET['paged'] - 1 ) * 50; // get picture values $picturelist = $nggdb->get_gallery($act_gid, $ngg->options['galSort'], $ngg->options['galSortDir'], false, 50, $start ); // get the current author $act_author_user = get_userdata( (int) $gallery->author ); } // list all galleries $gallerylist = $nggdb->find_all_galleries(); //get the columns $image_columns = $wp_list_table->get_columns(); $hidden_columns = get_hidden_columns('nggallery-manage-images'); $num_columns = count($image_columns) - count($hidden_columns); $attr = (nggGallery::current_user_can( 'NextGEN Edit gallery options' )) ? '' : 'disabled="disabled"'; ?>


: title) ); ?>


()

: type="text" size="50" name="title" value="title; ?>" /> :
: :
: type="text" size="50" name="path" value="path; ?>" /> : manage_page->get_editable_user_ids( $user_ID ); if ( $editable_ids && count( $editable_ids ) > 1 && nggGallery::current_user_can( 'NextGEN Edit gallery author') ) wp_dropdown_users( array('include' => $editable_ids, 'name' => 'author', 'selected' => empty( $gallery->author ) ? 0 : $gallery->author ) ); else echo $act_author_user->display_name; ?>
    :
" /> " />
manage_page->pagination( 'top', $_GET['paged'], $nggdb->paged['total_objects'], $nggdb->paged['objects_per_page'] ); ?>
options['galSort'] == "sortorder") && (!$is_search) ) { ?>
print_column_headers(true); ?> print_column_headers(false); ?> options['thumbfix']) $thumbsize = 'width="' . $ngg->options['thumbwidth'] . '" height="' . $ngg->options['thumbheight'] . '"'; foreach($picturelist as $picture) { //for search result we need to check the capatibiliy if ( !nggAdmin::can_manage_this_gallery($picture->author) && $is_search ) continue; $counter++; $pid = (int) $picture->pid; $alternate = ( !isset($alternate) || $alternate == 'alternate' ) ? '' : 'alternate'; $exclude = ( $picture->exclude ) ? 'checked="checked"' : ''; $date = mysql2date(get_option('date_format'), $picture->imagedate); $time = mysql2date(get_option('time_format'), $picture->imagedate); ?> $column_display_name) { $class = "class='$image_column_key column-$image_column_key'"; $style = ''; if ( in_array($image_column_key, $hidden_columns) ) $style = ' style="display:none;"'; $attributes = $class . $style; switch ($image_column_key) { case 'cb' : $attributes = 'class="column-cb check-column"' . $style; ?> tags = wp_get_object_terms($pid, 'ngg_tag', 'fields=names'); if (is_array ($picture->tags) ) $picture->tags = implode(', ', $picture->tags); ?> '; ?>
scope="row"> style=""> > alttext) ) ? esc_html( $picture->filename ) : esc_html( stripslashes(nggGallery::i18n($picture->alttext)) ); ?>
meta_data) ): ?>
meta_data['width']; ?> x meta_data['height']; ?>

imageURL ) . '" title="' . esc_attr( sprintf(__('View "%s"'), sanitize_title ($picture->filename) )) . '">' . __('View', 'nggallery') . ''; $actions['meta'] = '' . __('Meta', 'nggallery') . ''; $actions['custom_thumb'] = '' . __('Edit thumb', 'nggallery') . ''; $actions['rotate'] = '' . __('Rotate', 'nggallery') . ''; if ( current_user_can( 'publish_posts' ) ) $actions['publish'] = '' . __('Publish', 'nggallery') . ''; if ( file_exists( $picture->imagePath . '_backup' ) ) $actions['recover'] = 'filename)). '\');if(check==false) return false;">' . __('Recover', 'nggallery') . ''; $actions['delete'] = 'filename)). '\');if(check==false) return false;">' . __('Delete') . ''; $action_count = count($actions); $i = 0; echo '

'; foreach ( $actions as $action => $link ) { ++$i; ( $i == $action_count ) ? $sep = '' : $sep = ' | '; echo "$link$sep"; } echo '
'; ?>

> >
> /> > >
'.__('No entries found','nggallery').'
manage_page->pagination( 'bottom', $_GET['paged'], $nggdb->paged['total_objects'], $nggdb->paged['objects_per_page'] ); ?>

_screen = $screen; $this->_columns = array() ; add_filter( 'manage_' . $screen->id . '_columns', array( &$this, 'get_columns' ), 0 ); } function get_column_info() { $columns = get_column_headers( $this->_screen ); $hidden = get_hidden_columns( $this->_screen ); $_sortable = $this->get_sortable_columns(); $sortable = array(); foreach ( $_sortable as $id => $data ) { if ( empty( $data ) ) continue; $data = (array) $data; if ( !isset( $data[1] ) ) $data[1] = false; $sortable[$id] = $data; } return array( $columns, $hidden, $sortable ); } // define the columns to display, the syntax is 'internal name' => 'display name' function get_columns() { $columns = array(); $columns['cb'] = ''; $columns['id'] = __('ID'); $columns['thumbnail'] = __('Thumbnail', 'nggallery'); $columns['filename'] = __('Filename', 'nggallery'); $columns['alt_title_desc'] = __('Alt & Title Text', 'nggallery') . ' / ' . __('Description', 'nggallery'); $columns['tags'] = __('Tags (comma separated list)', 'nggallery'); $columns['exclude'] = __('exclude', 'nggallery'); $columns = apply_filters('ngg_manage_images_columns', $columns); return $columns; } function get_sortable_columns() { return array(); } } ?>