Make WordPress Core


Ignore:
Timestamp:
01/07/2010 04:27:46 AM (14 years ago)
Author:
ryan
Message:

Strip trailing whites from ms files. see #11644

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/ms-sites.php

    r12629 r12632  
    8282        <form method="post" action="ms-edit.php?action=updateblog">
    8383            <?php wp_nonce_field('editblog'); ?>
    84             <input type="hidden" name="id" value="<?php echo esc_attr($id) ?>" /> 
     84            <input type="hidden" name="id" value="<?php echo esc_attr($id) ?>" />
    8585            <div class='metabox-holder' style='width:49%;float:left;'>
    8686            <div id="blogedit_bloginfo" class="postbox " >
     
    8989                <table class="form-table">
    9090                            <tr class="form-field form-required">
    91                                 <th scope="row"><?php _e('Domain') ?></th> 
     91                                <th scope="row"><?php _e('Domain') ?></th>
    9292                                <td>http://<input name="blog[domain]" type="text" id="domain" value="<?php echo $details['domain'] ?>" size="33" /></td>
    93                             </tr> 
     93                            </tr>
    9494                            <tr class="form-field form-required">
    95                                 <th scope="row"><?php _e('Path') ?></th> 
     95                                <th scope="row"><?php _e('Path') ?></th>
    9696                                <td><input name="blog[path]" type="text" id="path" value="<?php echo esc_attr($details['path']) ?>" size="40" style='margin-bottom:5px;' />
    9797                                <br /><input type='checkbox' style='width:20px;' name='update_home_url' value='update' <?php if( get_blog_option( $id, 'siteurl' ) == preg_replace('|/+$|', '', 'http://' . $details['domain'] . $details['path']) || get_blog_option( $id, 'home' ) == preg_replace('|/+$|', '', 'http://' . $details['domain'] . $details['path']) ) echo 'checked="checked"'; ?> /> <?php _e( "Update 'siteurl' and 'home' as well." ); ?></td>
    98                             </tr> 
     98                            </tr>
    9999                            <tr class="form-field">
    100                                 <th scope="row"><?php _e('Registered') ?></th> 
    101                                 <td><input name="blog[registered]" type="text" id="blog_registered" value="<?php echo esc_attr($details['registered']) ?>" size="40" /></td> 
    102                             </tr> 
     100                                <th scope="row"><?php _e('Registered') ?></th>
     101                                <td><input name="blog[registered]" type="text" id="blog_registered" value="<?php echo esc_attr($details['registered']) ?>" size="40" /></td>
     102                            </tr>
    103103                            <tr class="form-field">
    104                                 <th scope="row"><?php _e('Last Updated') ?></th> 
    105                                 <td><input name="blog[last_updated]" type="text" id="blog_last_updated" value="<?php echo esc_attr($details['last_updated']) ?>" size="40" /></td> 
    106                             </tr> 
     104                                <th scope="row"><?php _e('Last Updated') ?></th>
     105                                <td><input name="blog[last_updated]" type="text" id="blog_last_updated" value="<?php echo esc_attr($details['last_updated']) ?>" size="40" /></td>
     106                            </tr>
    107107                            <tr class="form-field">
    108                                 <th scope="row"><?php _e('Public') ?></th> 
     108                                <th scope="row"><?php _e('Public') ?></th>
    109109                                <td>
    110110                                    <input type='radio' style='width:20px;' name='blog[public]' value='1' <?php if( $details['public'] == '1' ) echo 'checked="checked"'; ?> /> <?php _e('Yes') ?>
    111111                                    <input type='radio' style='width:20px;' name='blog[public]' value='0' <?php if( $details['public'] == '0' ) echo 'checked="checked"'; ?> /> <?php _e('No') ?>
    112                                 </td> 
    113                             </tr> 
     112                                </td>
     113                            </tr>
    114114                            <tr class="form-field">
    115                                 <th scope="row"><?php _e( 'Archived' ); ?></th> 
     115                                <th scope="row"><?php _e( 'Archived' ); ?></th>
    116116                                <td>
    117117                                    <input type='radio' style='width:20px;' name='blog[archived]' value='1' <?php if( $details['archived'] == '1' ) echo 'checked="checked"'; ?> /> <?php _e('Yes') ?>
    118118                                    <input type='radio' style='width:20px;' name='blog[archived]' value='0' <?php if( $details['archived'] == '0' ) echo 'checked="checked"'; ?> /> <?php _e('No') ?>
    119                                 </td> 
    120                             </tr> 
     119                                </td>
     120                            </tr>
    121121                            <tr class="form-field">
    122                                 <th scope="row"><?php _e( 'Mature' ); ?></th> 
     122                                <th scope="row"><?php _e( 'Mature' ); ?></th>
    123123                                <td>
    124124                                    <input type='radio' style='width:20px;' name='blog[mature]' value='1' <?php if( $details['mature'] == '1' ) echo 'checked="checked"'; ?> /> <?php _e('Yes') ?>
    125125                                    <input type='radio' style='width:20px;' name='blog[mature]' value='0' <?php if( $details['mature'] == '0' ) echo 'checked="checked"'; ?> /> <?php _e('No') ?>
    126                                 </td> 
    127                             </tr> 
     126                                </td>
     127                            </tr>
    128128                            <tr class="form-field">
    129                                 <th scope="row"><?php _e( 'Spam' ); ?></th> 
     129                                <th scope="row"><?php _e( 'Spam' ); ?></th>
    130130                                <td>
    131131                                    <input type='radio' style='width:20px;' name='blog[spam]' value='1' <?php if( $details['spam'] == '1' ) echo 'checked="checked"'; ?> /> <?php _e('Yes') ?>
    132132                                    <input type='radio' style='width:20px;' name='blog[spam]' value='0' <?php if( $details['spam'] == '0' ) echo 'checked="checked"'; ?> /> <?php _e('No') ?>
    133                                 </td> 
    134                             </tr> 
     133                                </td>
     134                            </tr>
    135135                            <tr class="form-field">
    136                                 <th scope="row"><?php _e( 'Deleted' ); ?></th> 
     136                                <th scope="row"><?php _e( 'Deleted' ); ?></th>
    137137                                <td>
    138138                                    <input type='radio' style='width:20px;' name='blog[deleted]' value='1' <?php if( $details['deleted'] == '1' ) echo 'checked="checked"'; ?> /> <?php _e('Yes') ?>
    139139                                    <input type='radio' style='width:20px;' name='blog[deleted]' value='0' <?php if( $details['deleted'] == '0' ) echo 'checked="checked"'; ?> /> <?php _e('No') ?>
    140                                 </td> 
    141                             </tr> 
     140                                </td>
     141                            </tr>
    142142                        </table>
    143143                        <p class="submit" style="margin:-15px 0 -5px 230px;"><input type="submit" name="Submit" value="<?php esc_attr_e('Update Options') ?>" /></p>
    144144            </div></div>
    145            
     145
    146146            <div id="blogedit_blogoptions" class="postbox " >
    147147            <h3 class='hndle'><span><?php printf( __('Blog options (wp_%s_options)'), $id ); ?></span></h3>
     
    166166                                ?>
    167167                                    <tr class="form-field">
    168                                         <th scope="row"><?php echo ucwords( str_replace( "_", " ", $val['option_name'] ) ) ?></th> 
     168                                        <th scope="row"><?php echo ucwords( str_replace( "_", " ", $val['option_name'] ) ) ?></th>
    169169                                        <td><textarea rows="5" cols="40" name="option[<?php echo $val['option_name'] ?>]" type="text" id="<?php echo $val['option_name'] ?>"<?php echo $disabled ?>><?php echo wp_specialchars( stripslashes( $val['option_value'] ), 1 ) ?></textarea></td>
    170170                                    </tr>
     
    173173                                ?>
    174174                                    <tr class="form-field">
    175                                         <th scope="row"><?php echo ucwords( str_replace( "_", " ", $val['option_name'] ) ) ?></th> 
    176                                         <td><input name="option[<?php echo $val['option_name'] ?>]" type="text" id="<?php echo $val['option_name'] ?>" value="<?php echo esc_attr( stripslashes( $val['option_value'] ), 1 ) ?>" size="40" <?php echo $disabled ?> /></td> 
    177                                     </tr> 
     175                                        <th scope="row"><?php echo ucwords( str_replace( "_", " ", $val['option_name'] ) ) ?></th>
     176                                        <td><input name="option[<?php echo $val['option_name'] ?>]" type="text" id="<?php echo $val['option_name'] ?>" value="<?php echo esc_attr( stripslashes( $val['option_value'] ), 1 ) ?>" size="40" <?php echo $disabled ?> /></td>
     177                                    </tr>
    178178                                <?php
    179179                                }
     
    184184            </div></div>
    185185            </div>
    186            
     186
    187187            <div class='metabox-holder' style='width:49%;float:right;'>
    188188            <?php
     
    200200                            $checked = ( isset($blog_allowed_themes[ $theme_key ]) ) ? 'checked="checked"' : '';
    201201                            $out .= '<tr class="form-field form-required">
    202                                     <th title="'.htmlspecialchars( $theme["Description"] ).'" scope="row">'.$key.'</th> 
    203                                     <td><input name="theme['.$theme_key.']" type="checkbox" style="width:20px;" value="on" '.$checked.'/>' . __( 'Active' ) . '</td> 
     202                                    <th title="'.htmlspecialchars( $theme["Description"] ).'" scope="row">'.$key.'</th>
     203                                    <td><input name="theme['.$theme_key.']" type="checkbox" style="width:20px;" value="on" '.$checked.'/>' . __( 'Active' ) . '</td>
    204204                                </tr>';
    205205                        }
    206206                    }
    207                    
     207
    208208                    if ( $out != '' ) {
    209209            ?>
     
    218218            </div></div>
    219219            <?php } ?>
    220            
     220
    221221            <?php
    222222                    // Blog users
     
    237237                                ?>
    238238                                <td>
    239                                     <select name="role[<?php echo $val->user_id ?>]" id="new_role"><?php 
     239                                    <select name="role[<?php echo $val->user_id ?>]" id="new_role"><?php
    240240                                        foreach( $editblog_roles as $role => $role_assoc ){
    241241                                            $name = translate_with_context($role_assoc['name']);
     
    261261                    }
    262262            ?>
    263            
     263
    264264            <div id="blogedit_blogadduser" class="postbox">
    265265            <h3 class='hndle'><span><?php _e('Add a new user'); ?></span></h3>
     
    275275                            <td>
    276276                                <select name="new_role" id="new_role">
    277                                 <?php 
     277                                <?php
    278278                                reset( $editblog_roles );
    279279                                foreach( $editblog_roles as $role => $role_assoc ){
     
    289289                <p class="submit" style="margin:-15px 0 -5px 230px;"><input type="submit" name="Submit" value="<?php esc_attr_e('Update Options') ?>" /></p>
    290290            </div></div>
    291            
     291
    292292            <div id="blogedit_miscoptions" class="postbox">
    293293            <h3 class='hndle'><span><?php _e('Misc Blog Actions') ?></span></h3>
     
    298298                <p class="submit" style="margin:-15px 0 -5px 230px;"><input type="submit" name="Submit" value="<?php esc_attr_e('Update Options') ?>" /></p>
    299299            </div></div>
    300            
     300
    301301            </div>
    302            
     302
    303303            <div style="clear:both;"></div>
    304304        </form>
     
    325325                AND {$wpdb->blogs}.blog_id = {$wpdb->registration_log}.blog_id
    326326                AND {$wpdb->registration_log}.IP LIKE ('%{$s}%')";
    327         } 
     327        }
    328328
    329329        if( isset( $_GET['sortby'] ) == false ) {
     
    408408            'users'        => __('Users')
    409409        );
    410        
     410
    411411        if( has_filter( 'wpmublogsaction' ) )
    412412            $posts_columns['plugins'] = __('Actions');
    413            
     413
    414414        $posts_columns = apply_filters('wpmu_blogs_columns', $posts_columns);
    415415
     
    428428                <?php foreach($posts_columns as $column_id => $column_display_name) {
    429429                    $column_link = "<a href='ms-blogs.php?{$sortby_url}&amp;sortby={$column_id}&amp;";
    430                     if( $_GET['sortby'] == $column_id ) { 
     430                    if( $_GET['sortby'] == $column_id ) {
    431431                        $column_link .= $_GET[ 'order' ] == 'DESC' ? 'order=ASC&amp;' : 'order=DESC&amp;';
    432432                    }
     
    444444                $bgcolor = $class = '';
    445445                $status_list = array( "archived" => "#fee", "spam" => "#faa", "deleted" => "#f55" );
    446                 foreach ($blog_list as $blog) { 
     446                foreach ($blog_list as $blog) {
    447447                    $class = ('alternate' == $class) ? '' : 'alternate';
    448448                    reset( $status_list );
     
    456456                    echo "<tr $bgcolour class='$class'>";
    457457
    458                     $blogname = ( constant( "VHOST" ) == 'yes' ) ? str_replace('.'.$current_site->domain, '', $blog['domain']) : $blog['path']; 
     458                    $blogname = ( constant( "VHOST" ) == 'yes' ) ? str_replace('.'.$current_site->domain, '', $blog['domain']) : $blog['path'];
    459459                    foreach( $posts_columns as $column_name=>$column_display_name ) {
    460460                        switch($column_name) {
     
    468468                            <?php
    469469                            break;
    470  
     470
    471471                            case 'blogname': ?>
    472472                                <td valign="top">
     
    477477                                    $controlActions[]   = '<a href="ms-blogs.php?action=editblog&amp;id=' . $blog['blog_id'] . '" class="edit">' . __('Edit') . '</a>';
    478478                                    $controlActions[]   = "<a href='{$protocol}{$blog['domain']}{$blog['path']}wp-admin/' class='edit'>" . __('Backend') . '</a>';
    479                                    
     479
    480480                                    if( get_blog_status( $blog['blog_id'], "deleted" ) == '1' )
    481481                                        $controlActions[]   = '<a class="delete" href="ms-edit.php?action=confirm&amp;action2=activateblog&amp;ref=' . urlencode( $_SERVER['REQUEST_URI'] ) . '&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( "You are about to activate the blog %s" ), $blogname ) ) . '">' . __('Activate') . '</a>';
    482482                                    else
    483483                                        $controlActions[]   = '<a class="delete" href="ms-edit.php?action=confirm&amp;action2=deactivateblog&amp;ref=' . urlencode( $_SERVER['REQUEST_URI'] ) . '&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( "You are about to deactivate the blog %s" ), $blogname ) ) . '">' . __('Deactivate') . '</a>';
    484                                    
     484
    485485                                    if( get_blog_status( $blog['blog_id'], "archived" ) == '1' )
    486486                                        $controlActions[]   = '<a class="delete" href="ms-edit.php?action=confirm&amp;action2=unarchiveblog&amp;id=' .  $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( "You are about to unarchive the blog %s" ), $blogname ) ) . '">' . __('Unarchive') . '</a>';
    487487                                    else
    488488                                        $controlActions[]   = '<a class="delete" href="ms-edit.php?action=confirm&amp;action2=archiveblog&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( "You are about to archive the blog %s" ), $blogname ) ) . '">' . __('Archive') . '</a>';
    489                                    
     489
    490490                                    if( get_blog_status( $blog['blog_id'], "spam" ) == '1' )
    491491                                        $controlActions[]   = '<a class="delete" href="ms-edit.php?action=confirm&amp;action2=unspamblog&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( "You are about to unspam the blog %s" ), $blogname ) ) . '">' . __('Not Spam') . '</a>';
    492492                                    else
    493493                                        $controlActions[]   = '<a class="delete" href="ms-edit.php?action=confirm&amp;action2=spamblog&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( "You are about to mark the blog %s as spam" ), $blogname ) ) . '">' . __("Spam") . '</a>';
    494                                    
     494
    495495                                    $controlActions[]   = '<a class="delete" href="ms-edit.php?action=confirm&amp;action2=deleteblog&amp;id=' . $blog['blog_id'] . '&amp;msg=' . urlencode( sprintf( __( "You are about to delete the blog %s" ), $blogname ) ) . '">' . __("Delete") . '</a>';
    496                                    
     496
    497497                                    $controlActions[]   = "<a href='http://{$blog['domain']}{$blog['path']}' rel='permalink'>" . __('Visit') . '</a>';
    498498                                    ?>
    499                                    
     499
    500500                                    <?php if (count($controlActions)) : ?>
    501501                                    <div class="row-actions">
     
    506506                            <?php
    507507                            break;
    508  
     508
    509509                            case 'lastupdated': ?>
    510510                                <td valign="top">
     
    523523                                <td valign="top">
    524524                                    <?php
    525                                     $blogusers = get_users_of_blog( $blog['blog_id'] ); 
     525                                    $blogusers = get_users_of_blog( $blog['blog_id'] );
    526526                                    if ( is_array( $blogusers ) ) {
    527527                                        $blogusers_warning = '';
     
    531531                                        }
    532532                                        foreach ( $blogusers as $key => $val ) {
    533                                             echo '<a href="user-edit.php?user_id=' . $val->user_id . '">' . $val->user_login . '</a> ('.$val->user_email.')<br />'; 
     533                                            echo '<a href="user-edit.php?user_id=' . $val->user_id . '">' . $val->user_login . '</a> ('.$val->user_email.')<br />';
    534534                                        }
    535535                                        if( $blogusers_warning != '' ) {
     
    549549                                <?php } ?>
    550550                            <?php break;
    551  
     551
    552552                            default: ?>
    553553                                <?php if( has_filter( 'manage_blogs_custom_column' ) ) { ?>
     
    564564                }
    565565            } else { ?>
    566                 <tr style='background-color: <?php echo $bgcolor; ?>'> 
    567                     <td colspan="8"><?php _e('No blogs found.') ?></td> 
    568                 </tr> 
     566                <tr style='background-color: <?php echo $bgcolor; ?>'>
     567                    <td colspan="8"><?php _e('No blogs found.') ?></td>
     568                </tr>
    569569            <?php
    570570            } // end if ($blogs)
     
    586586                        <td>
    587587                        <?php if ( constant( "VHOST" ) == 'yes' ) { ?>
    588                             <input name="blog[domain]" type="text" title="<?php _e('Domain') ?>"/>.<?php echo $current_site->domain;?> 
     588                            <input name="blog[domain]" type="text" title="<?php _e('Domain') ?>"/>.<?php echo $current_site->domain;?>
    589589                        <?php } else {
    590590                            echo $current_site->domain . $current_site->path ?><input name="blog[domain]" type="text" title="<?php _e('Domain') ?>"/>
    591                         <?php } 
     591                        <?php }
    592592                        echo "<p>" . __( 'Only the characters a-z and 0-9 recommended.' ) . "</p>";
    593593                        ?>
Note: See TracChangeset for help on using the changeset viewer.