WordPress.org

Make WordPress Core

Changeset 19081


Ignore:
Timestamp:
10/28/2011 10:40:09 PM (7 years ago)
Author:
nacin
Message:

Use esc_attr() consistently in wp_dropdown_pages().

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/post-template.php

    r19069 r19081  
    779779    $pages = get_pages($r);
    780780    $output = '';
    781     $name = esc_attr($name);
    782781    // Back-compat with old system where both id and name were based on $name argument
    783782    if ( empty($id) )
     
    785784
    786785    if ( ! empty($pages) ) {
    787         $output = "<select name=\"$name\" id=\"$id\">\n";
     786        $output = "<select name='" . esc_attr( $name ) . "' id='" . esc_attr( $id ) . "'>\n";
    788787        if ( $show_option_no_change )
    789788            $output .= "\t<option value=\"-1\">$show_option_no_change</option>";
Note: See TracChangeset for help on using the changeset viewer.