Make WordPress Core


Ignore:
Timestamp:
09/29/2008 09:26:21 AM (16 years ago)
Author:
azaozz
Message:

Add table footers and action selects at the bottom

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/users.php

    r9016 r9028  
    1919$parent_file = 'users.php';
    2020
    21 $action = isset($_REQUEST['action']) ? $_REQUEST['action'] : '';
    22 $update = '';
    23 
    24 if ( empty($action) ) {
     21$update = $doaction = '';
     22if ( isset($_REQUEST['action']) )
     23    $doaction = $_REQUEST['action'] ? $_REQUEST['action'] : $_REQUEST['action2'];
     24
     25if ( empty($doaction) ) {
    2526    if ( isset($_GET['changeit']) && !empty($_GET['new_role']) )
    26         $action = 'promote';
     27        $doaction = 'promote';
    2728}
    2829
     
    3738}
    3839
    39 switch ($action) {
     40switch ($doaction) {
    4041
    4142case 'promote':
     
    208209    $userspage = isset($_GET['userspage']) ? $_GET['userspage'] : null;
    209210    $role = isset($_GET['role']) ? $_GET['role'] : null;
    210    
     211
    211212    // Query the users
    212213    $wp_user_search = new WP_User_Search($usersearch, $userspage, $role);
    213    
     214
    214215    $messages = array();
    215216    if ( isset($_GET['update']) ) :
     
    259260        </ul>
    260261    </div>
    261 <?php endif; 
     262<?php endif;
    262263
    263264if ( ! empty($messages) ) {
     
    359360</tr>
    360361</thead>
     362
     363<tfoot>
     364<tr class="thead">
     365<?php print_column_headers('user', false) ?>
     366</tr>
     367</tfoot>
     368
    361369<tbody id="users" class="list:user user-list">
    362370<?php
     
    379387    <div class="tablenav-pages"><?php $wp_user_search->page_links(); ?></div>
    380388<?php endif; ?>
     389
     390<div class="alignleft">
     391<select name="action2">
     392<option value="" selected><?php _e('Actions'); ?></option>
     393<option value="delete"><?php _e('Delete'); ?></option>
     394</select>
     395<input type="submit" value="<?php _e('Apply'); ?>" name="doaction2" id="doaction2" class="button-secondary action" />
     396</div>
    381397
    382398<br class="clear" />
     
    475491break;
    476492
    477 } // end of the $action switch
     493} // end of the $doaction switch
    478494
    479495include('admin-footer.php');
Note: See TracChangeset for help on using the changeset viewer.