WordPress.org

Make WordPress Core


Ignore:
Timestamp:
05/18/2009 04:00:33 PM (12 years ago)
Author:
markjaquith
Message:

Deprecate sanitize_url() and clean_url() in favor of esc_url_raw() and esc_url()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/plugin-install.php

    r11362 r11383  
    139139    foreach ( (array)$api_tags as $tag )
    140140        $tags[ $tag['name'] ] = (object) array(
    141                                 'link' => clean_url( admin_url('plugin-install.php?tab=search&type=tag&s=' . urlencode($tag['name'])) ),
     141                                'link' => esc_url( admin_url('plugin-install.php?tab=search&type=tag&s=' . urlencode($tag['name'])) ),
    142142                                'name' => $tag['name'],
    143143                                'id' => sanitize_title_with_dashes($tag['name']),
     
    274274        </div>
    275275        <?php
    276             $url = clean_url($_SERVER['REQUEST_URI']);
     276            $url = esc_url($_SERVER['REQUEST_URI']);
    277277            if ( ! empty($term) )
    278278                $url = add_query_arg('s', $term, $url);
     
    428428        $class = ( $section_name == $section ) ? ' class="current"' : '';
    429429        $href = add_query_arg( array('tab' => $tab, 'section' => $section_name) );
    430         $href = clean_url($href);
     430        $href = esc_url($href);
    431431        $san_title = esc_attr(sanitize_title_with_dashes($title));
    432432        echo "\t<li><a name='$san_title' target='' href='$href'$class>$title</a></li>\n";
Note: See TracChangeset for help on using the changeset viewer.