diff --git wp-admin/includes/user.php wp-admin/includes/user.php
index 5b6c6ffd8b..2c92df5c51 100644
|
|
function edit_user( $user_id = 0 ) { |
132 | 132 | } |
133 | 133 | |
134 | 134 | if ( $update ) { |
135 | | $user->rich_editing = isset( $_POST['rich_editing'] ) && 'false' === $_POST['rich_editing'] ? 'false' : 'true'; |
136 | | $user->syntax_highlighting = isset( $_POST['syntax_highlighting'] ) && 'false' === $_POST['syntax_highlighting'] ? 'false' : 'true'; |
| 135 | $user->rich_editing = isset( $_POST['rich_editing'] ) ? 'true' : 'false'; |
| 136 | $user->syntax_highlighting = isset( $_POST['syntax_highlighting'] ) ? 'true' : 'false'; |
137 | 137 | $user->admin_color = isset( $_POST['admin_color'] ) ? sanitize_text_field( $_POST['admin_color'] ) : 'fresh'; |
138 | 138 | $user->show_admin_bar_front = isset( $_POST['admin_bar_front'] ) ? 'true' : 'false'; |
139 | 139 | } |
diff --git wp-admin/user-edit.php wp-admin/user-edit.php
index af1d72193d..3e9d50bf0c 100644
|
|
switch ( $action ) { |
272 | 272 | <tr class="user-rich-editing-wrap"> |
273 | 273 | <th scope="row"><?php _e( 'Visual Editor' ); ?></th> |
274 | 274 | <td> |
275 | | <label for="rich_editing"><input name="rich_editing" type="checkbox" id="rich_editing" value="false" <?php checked( 'false', $profile_user->rich_editing ); ?> /> |
276 | | <?php _e( 'Disable the visual editor when writing' ); ?> |
| 275 | <label for="rich_editing"><input name="rich_editing" type="checkbox" id="rich_editing" value="true"<?php checked( 'true', $profile_user->rich_editing ); ?> /> |
| 276 | <?php _e( 'Enable the visual editor when writing' ); ?> |
277 | 277 | </label> |
278 | 278 | </td> |
279 | 279 | </tr> |
… |
… |
switch ( $action ) { |
296 | 296 | <tr class="user-syntax-highlighting-wrap"> |
297 | 297 | <th scope="row"><?php _e( 'Syntax Highlighting' ); ?></th> |
298 | 298 | <td> |
299 | | <label for="syntax_highlighting"><input name="syntax_highlighting" type="checkbox" id="syntax_highlighting" value="false" <?php checked( 'false', $profile_user->syntax_highlighting ); ?> /> |
300 | | <?php _e( 'Disable syntax highlighting when editing code' ); ?> |
| 299 | <label for="syntax_highlighting"><input name="syntax_highlighting" type="checkbox" id="syntax_highlighting" value="true"<?php checked( 'true', $profile_user->syntax_highlighting ); ?> /> |
| 300 | <?php _e( 'Enable syntax highlighting when editing code' ); ?> |
301 | 301 | </label> |
302 | 302 | </td> |
303 | 303 | </tr> |
… |
… |
switch ( $action ) { |
342 | 342 | <th scope="row"><?php _e( 'Toolbar' ); ?></th> |
343 | 343 | <td> |
344 | 344 | <label for="admin_bar_front"> |
345 | | <input name="admin_bar_front" type="checkbox" id="admin_bar_front" value="1"<?php checked( _get_admin_bar_pref( 'front', $profile_user->ID ) ); ?> /> |
| 345 | <input name="admin_bar_front" type="checkbox" id="admin_bar_front" value="true"<?php checked( _get_admin_bar_pref( 'front', $profile_user->ID ) ); ?> /> |
346 | 346 | <?php _e( 'Show Toolbar when viewing site' ); ?> |
347 | 347 | </label><br /> |
348 | 348 | </td> |