- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3.1/wp-includes/formatting.php
r18356 r18031 2441 2441 } 2442 2442 break; 2443 case 'new_admin_email': 2444 $value = sanitize_email($value); 2445 if ( !is_email($value) ) { 2446 $value = get_option( $option ); // Resets option to stored value in the case of failed sanitization 2447 if ( function_exists('add_settings_error') ) 2448 add_settings_error('new_admin_email', 'invalid_admin_email', __('The email address entered did not appear to be a valid email address. Please enter a valid email address.')); 2449 } 2450 break; 2443 2451 2444 case 'thumbnail_size_w': 2452 2445 case 'thumbnail_size_h': … … 2542 2535 } 2543 2536 break; 2544 case 'WPLANG':2545 $allowed = get_available_languages();2546 if ( ! in_array( $value, $allowed ) && ! empty( $value ) )2547 $value = get_option( $option );2548 break;2549 2537 2550 2538 default : … … 2925 2913 */ 2926 2914 function sanitize_mime_type( $mime_type ) { 2927 $sani_mime_type = preg_replace( '/[^- +*.a-zA-Z0-9\/]/', '', $mime_type );2915 $sani_mime_type = preg_replace( '/[^-*.a-zA-Z0-9\/]/', '', $mime_type ); 2928 2916 return apply_filters( 'sanitize_mime_type', $sani_mime_type, $mime_type ); 2929 2917 }
Note: See TracChangeset
for help on using the changeset viewer.