WordPress.org

WordPress MU

Changeset 860


Ignore:
Timestamp:
01/22/07 18:52:20 (7 years ago)
Author:
donncha
Message:

Removed autocomplete_css() because it possibly conflicts with advanced editor stuff:
http://trac.mu.wordpress.org/ticket/213
http://trac.mu.wordpress.org/ticket/176
http://trac.mu.wordpress.org/ticket/217

Location:
trunk/wp-admin
Files:
7 edited

Legend:

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

    r851 r860  
    22342234} 
    22352235 
    2236 function autocomplete_css() { 
    2237     ?> 
    2238 <style type='text/css'> 
    2239     div.autocomplete { 
    2240       position:absolute; 
    2241       width:200px; 
    2242       background-color:white; 
    2243       border:1px solid #888; 
    2244       margin:0px; 
    2245       padding:0px; 
    2246     } 
    2247     div.autocomplete ul { 
    2248       list-style-type:none; 
    2249       margin:0px; 
    2250       padding:0px; 
    2251     } 
    2252     div.autocomplete ul li.selected { background-color: #ffb;} 
    2253     div.autocomplete ul li { 
    2254       list-style-type:none; 
    2255       display:block; 
    2256       margin:0; 
    2257       padding:2px; 
    2258       height:32px; 
    2259       cursor:pointer; 
    2260     } 
    2261 </style> 
    2262 <?php 
    2263 } 
    2264 function autocomplete_textbox( $url, $search_field, $results_field ) { 
    2265     wp_print_scripts('scriptaculous-controls'); 
    2266     ?> 
    2267  
    2268 <script type="text/javascript"> 
    2269 function load_autocompleter() { 
    2270     new Ajax.Autocompleter("<?php echo $search_field ?>", "<?php echo $results_field ?>", "<?php echo $url ?>", {paramName: "search", minChars: 3}); 
    2271 } 
    2272 addLoadEvent( load_autocompleter ); 
    2273 </script> 
    2274 <?php 
    2275 } 
    22762236 
    22772237function update_blog_public($old_value, $value) { 
  • trunk/wp-admin/edit-category-form.php

    r828 r860  
    2424<input type="hidden" name="cat_ID" value="<?php echo $category->cat_ID ?>" /> 
    2525<?php wp_nonce_field($nonce_action); ?> 
    26 <?php autocomplete_css(); ?> 
    2726    <table class="editform" width="100%" cellspacing="2" cellpadding="5"> 
    2827        <tr> 
    2928            <th width="33%" scope="row" valign="top"><label for="cat_name"><?php _e('Category name:') ?></label></th> 
    30             <td width="67%"><input name="cat_name" id="cat_name" type="text" value="<?php echo attribute_escape($category->cat_name); ?>" size="40" /><div id="searchresults" class="autocomplete"></div></td> 
     29            <td width="67%"><input name="cat_name" id="cat_name" type="text" value="<?php echo attribute_escape($category->cat_name); ?>" size="40" /></td> 
    3130        </tr> 
    3231        <tr> 
     
    4140        </tr> 
    4241    </table> 
    43 <?php autocomplete_textbox( "wpmu-edit.php?action=searchcategories&search=", "cat_name", "searchresults" ); ?> 
    4442<p class="submit"><input type="submit" name="submit" value="<?php echo $submit_text ?>" /></p> 
    4543<?php do_action('edit_category_form', $category); ?> 
  • trunk/wp-admin/edit-form-advanced.php

    r851 r860  
    6464</script> 
    6565<?php endif; ?> 
    66 <?php autocomplete_css(); ?> 
    6766<div id="poststuff"> 
    6867 
     
    7473<div class="dbx-content"> 
    7574<p id="jaxcat"></p> 
    76 <?php if ( current_user_can('manage_categories') ) : ?> 
    77 <div id="searchresults" class="autocomplete"></div> 
    78 <?php autocomplete_textbox( "wpmu-edit.php?action=searchcategories&search=", "newcat", "searchresults" ); ?> 
    79 <?php endif; ?> 
    8075<ul id="categorychecklist"><?php dropdown_categories(); ?></ul></div> 
    8176</fieldset> 
  • trunk/wp-admin/edit-link-form.php

    r828 r860  
    4040<div id="grabit" class="dbx-group"> 
    4141 
    42 <?php autocomplete_css(); ?> 
    4342<fieldset id="categorydiv" class="dbx-box"> 
    4443<h3 class="dbx-handle"><?php _e('Categories') ?></h3> 
    4544<div class="dbx-content"> 
    4645<p id="jaxcat"></p> 
    47 <?php if ( current_user_can('manage_categories') ) : ?> 
    48 <div id="searchresults" class="autocomplete"></div> 
    49 <?php autocomplete_textbox( "wpmu-edit.php?action=searchcategories&search=", "newcat", "searchresults" ); ?> 
    50 <?php endif; ?> 
    51 <ul id="categorychecklist"><?php dropdown_categories(get_option('default_link_category')); ?></ul> 
     46<ul id="categorychecklist"><?php dropdown_link_categories(get_option('default_link_category')); ?></ul> 
    5247</div> 
    5348</fieldset> 
  • trunk/wp-admin/wpmu-blogs.php

    r847 r860  
    200200    print "<h3>" . __('Add a new user') . "</h3>"; 
    201201    ?> 
    202 <?php autocomplete_css(); ?> 
    203202<p><?php _e('As you type WordPress will offer you a choice of usernames.<br /> Click them to select and hit <em>Update Options</em> to add the user.') ?></p> 
    204203<table> 
    205204<tr><th scope="row"><?php _e('User&nbsp;Login:') ?> </th><td><input type="text" name="newuser" id="newuser"></td></tr> 
    206 <tr><td></td><td><div id="searchresults" class="autocomplete"></div></td> </tr> 
     205<tr><td></td><td></td> </tr> 
    207206    <tr> 
    208207        <th scope="row"><?php _e('Role:') ?></th> 
     
    223222<p class="submit"> 
    224223<input type="submit" name="Submit" value="<?php _e('Update Options') ?> &raquo;" /> 
    225 </p>  
    226 <?php autocomplete_textbox( "wpmu-edit.php?action=searchusers&search=", "newuser", "searchresults" ); ?> 
     224</p> 
    227225 
    228226    </td> 
     
    314312 
    315313<h2><?php _e ('Blogs') ?></h2> 
    316 <form name="searchform" action="wpmu-blogs.php" method="get" style="float: left; width: 16em; margin-right: 3em;">  
     314<form name="searchform" action="wpmu-blogs.php" method="get" style="float: left; margin-right: 3em;">  
    317315  <table><td> 
    318316  <fieldset>  
     
    329327  } 
    330328  ?> 
    331   </td><td> 
     329  </td><td valign='top'> 
    332330  <fieldset>  
    333331  <legend><?php _e('Blog Navigation') ?></legend>  
  • trunk/wp-admin/wpmu-edit.php

    r844 r860  
    2525        } 
    2626        if( $_POST[ 'banned_email_domains' ] != '' ) { 
    27             update_site_option( "banned_email_domains", split( ' ', $_POST[ 'banned_email_domains' ] ) ); 
     27            update_site_option( "banned_email_domains", split( ' ', stripslashes($_POST[ 'banned_email_domains' ]) ) ); 
    2828        } else { 
    2929            update_site_option( "banned_email_domains", '' ); 
     
    213213                    $_POST[ 'pass1' ] = $_POST[ 'pass2' ] = $pass; 
    214214                    $_POST[ 'email' ] = $userdata->user_email; 
     215                    $_POST[ 'rich_editing' ] = $userdata->rich_editing; 
    215216                    edit_user( $userid ); 
    216217                    if( $cap == null ) 
     
    241242        if( $id != '0' && $id != '1' ) 
    242243            wpmu_delete_blog( $id, true ); 
    243         wp_redirect( add_query_arg( "updated", "blogdeleted", $_POST[ 'ref' ] ) ); 
     244        wp_redirect( add_query_arg( "updated", "blogdeleted", $_SERVER[ 'HTTP_REFERER' ] ) ); 
    244245        die(); 
    245246    break; 
     
    255256                        wpmu_delete_blog( $val, true ); 
    256257                    } elseif( $_POST[ 'blogfunction' ] == 'spam' ) { 
    257                         update_blog_status( $val, "spam", '1' ); 
     258                        update_blog_status( $val, "spam", '1', 0 ); 
     259                        set_time_limit(60);  
    258260                    } 
    259261                } 
  • trunk/wp-admin/wpmu-users.php

    r846 r860  
    3333                        wpmu_delete_user($val); 
    3434                    } elseif( $_POST[ 'userfunction' ] == 'spam' ) { 
    35                         $blogs = get_blogs_of_user( $val ); 
     35                        $blogs = get_blogs_of_user( $val, true ); 
    3636                        if( is_array( $blogs ) ) { 
    3737                            while( list( $key, $details ) = each( $blogs ) ) {  
     
    4444            } 
    4545        } 
    46         wpmu_admin_do_redirect( $_SERVER['HTTP_REFERER'] ); 
     46        wp_redirect( add_query_arg( "updated", "true", $_SERVER[ 'HTTP_REFERER' ] ) ); 
    4747        die(); 
    4848    break; 
     
    295295 
    296296    case 'blogs': 
    297         $blogs = get_blogs_of_user( $user[ 'ID' ] ); 
     297        $blogs = get_blogs_of_user( $user[ 'ID' ], true ); 
    298298        ?> 
    299299        <td><?php if( is_array( $blogs ) )  
     
    342342<p><?php _e('Selected Users:') ?></p> 
    343343<ul> 
     344    <?php wp_nonce_field( "allusers" ); ?> 
    344345<li><input type='radio' name='userfunction' id='delete' value='delete' /> <label for='delete'><?php _e('Delete') ?></label></li> 
    345346<li><input type='radio' name='userfunction' id='spam' value='spam' /> <label for='spam'><?php _e('Mark as Spammers') ?></label></li> 
Note: See TracChangeset for help on using the changeset viewer.