Make WordPress Core


Ignore:
Timestamp:
08/24/2006 10:33:16 PM (18 years ago)
Author:
ryan
Message:

Make those chars feel special.

File:
1 edited

Legend:

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

    r4100 r4112  
    302302    $post->post_title = apply_filters('title_edit_pre', $post->post_title);
    303303
     304    $post->post_password = format_to_edit($post->post_password);
     305
    304306    if ($post->post_type == 'page')
    305307        $post->page_template = get_post_meta($id, '_wp_page_template', true);
     
    381383}
    382384
     385
     386function get_user_to_edit($user_id) {
     387    $user = new WP_User($user_id);
     388    $user->user_login = wp_specialchars($user->user_login, 1);
     389    $user->user_email = wp_specialchars($user->user_email, 1);
     390    $user->user_url = wp_specialchars($user->user_url, 1);
     391    $user->first_name = wp_specialchars($user->first_name, 1);
     392    $user->last_name = wp_specialchars($user->last_name, 1);
     393    $user->display_name = wp_specialchars($user->display_name, 1);
     394    $user->nickname = wp_specialchars($user->nickname, 1);
     395    $user->aim = wp_specialchars($user->aim, 1);
     396    $user->yim = wp_specialchars($user->yim, 1);
     397    $user->jabber = wp_specialchars($user->jabber, 1);
     398    $user->description = wp_specialchars($user->description);
     399
     400    return $user;
     401}
    383402
    384403// Creates a new user from the "Users" form using $_POST information.
     
    510529    $link->link_url = wp_specialchars($link->link_url, 1);
    511530    $link->link_name = wp_specialchars($link->link_name, 1);
    512     $link->link_description = wp_specialchars($link->link_description);
     531    $link->link_image = wp_specialchars($link->link_image, 1);
     532    $link->link_description = wp_specialchars($link->link_description, 1);
    513533    $link->link_notes = wp_specialchars($link->link_notes);
    514     $link->link_rss = wp_specialchars($link->link_rss);
     534    $link->link_rss = wp_specialchars($link->link_rss, 1);
     535    $link->link_rel = wp_specialchars($link->link_rel, 1);
    515536    $link->post_category = $link->link_category;
    516537
     
    960981        if ('_' == $entry['meta_key'] { 0 })
    961982            $style .= ' hidden';
    962         $key_js = addslashes(wp_specialchars( $entry['meta_key'], 'double' ));
     983        $key_js = js_escape($entry['meta_key']);
    963984        $entry['meta_key'] = wp_specialchars( $entry['meta_key'], true );
    964985        $entry['meta_value'] = wp_specialchars( $entry['meta_value'], true );
     
    10121033
    10131034    foreach ($keys as $key) {
     1035        $key = wp_specialchars($key, 1);
    10141036        echo "\n\t<option value='$key'>$key</option>";
    10151037    }
Note: See TracChangeset for help on using the changeset viewer.