Changeset 4656 for branches/2.0/wp-includes/functions.php
- Timestamp:
- 12/21/2006 10:10:04 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.0/wp-includes/functions.php
r4581 r4656 350 350 351 351 function form_option($option) { 352 echo wp_specialchars( get_option($option), 1);352 echo attribute_escape( get_option($option)); 353 353 } 354 354 … … 2363 2363 2364 2364 function wp_referer_field() { 2365 $ref = wp_specialchars($_SERVER['REQUEST_URI']);2365 $ref = attribute_escape(stripslashes($_SERVER['REQUEST_URI'])); 2366 2366 echo '<input type="hidden" name="_wp_http_referer" value="'. $ref . '" />'; 2367 2367 if ( wp_get_original_referer() ) { 2368 $original_ref = wp_specialchars(stripslashes(wp_get_original_referer()));2368 $original_ref = attribute_escape(stripslashes(wp_get_original_referer())); 2369 2369 echo '<input type="hidden" name="_wp_original_http_referer" value="'. $original_ref . '" />'; 2370 2370 } … … 2372 2372 2373 2373 function wp_original_referer_field() { 2374 echo '<input type="hidden" name="_wp_original_http_referer" value="' . wp_specialchars(stripslashes($_SERVER['REQUEST_URI'])) . '" />';2374 echo '<input type="hidden" name="_wp_original_http_referer" value="' . attribute_escape(stripslashes($_SERVER['REQUEST_URI'])) . '" />'; 2375 2375 } 2376 2376 … … 2457 2457 $adminurl = get_settings('siteurl') . '/wp-admin'; 2458 2458 if ( wp_get_referer() ) 2459 $adminurl = wp_get_referer();2459 $adminurl = attribute_escape(stripslashes(wp_get_referer())); 2460 2460 2461 2461 $title = __('WordPress Confirmation'); … … 2469 2469 $v = substr(strstr($a, '='), 1); 2470 2470 $k = substr($a, 0, -(strlen($v)+1)); 2471 $html .= "\t\t<input type='hidden' name='" . wp_specialchars( urldecode($k), 1 ) . "' value='" . wp_specialchars( urldecode($v), 1) . "' />\n";2471 $html .= "\t\t<input type='hidden' name='" . attribute_escape( urldecode($k)) . "' value='" . attribute_escape( urldecode($v)) . "' />\n"; 2472 2472 } 2473 2473 $html .= "\t\t<input type='hidden' name='_wpnonce' value='" . wp_create_nonce($action) . "' />\n"; 2474 2474 $html .= "\t\t<div id='message' class='confirm fade'>\n\t\t<p>" . wp_explain_nonce($action) . "</p>\n\t\t<p><a href='$adminurl'>" . __('No') . "</a> <input type='submit' value='" . __('Yes') . "' /></p>\n\t\t</div>\n\t</form>\n"; 2475 2475 } else { 2476 $html .= "\t<div id='message' class='confirm fade'>\n\t<p>" . wp_explain_nonce($action) . "</p>\n\t<p><a href='$adminurl'>" . __('No') . "</a> <a href='" . a dd_query_arg( '_wpnonce', wp_create_nonce($action), $_SERVER['REQUEST_URI']) . "'>" . __('Yes') . "</a></p>\n\t</div>\n";2476 $html .= "\t<div id='message' class='confirm fade'>\n\t<p>" . wp_explain_nonce($action) . "</p>\n\t<p><a href='$adminurl'>" . __('No') . "</a> <a href='" . attribute_escape(add_query_arg('_wpnonce', wp_create_nonce($action), $_SERVER['REQUEST_URI'])) . "'>" . __('Yes') . "</a></p>\n\t</div>\n"; 2477 2477 } 2478 2478 $html .= "</body>\n</html>";
Note: See TracChangeset
for help on using the changeset viewer.