Make WordPress Core


Ignore:
Timestamp:
04/16/2012 02:36:47 PM (13 years ago)
Author:
nacin
Message:

Theme Customizer: Stick to wp_customize_url() instead of wp_customize_href(). Switch argument order so it is stylesheet-template. (Template is hypothetically optional, but the function will not support that.) see #19910.

Move to ->display('Name'), as ->get('Name') is a raw, untranslated version of the header.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/theme.php

    r20476 r20477  
    16001600 * @since 3.4.0
    16011601 */
    1602 function wp_customize_url( $template, $stylesheet = null ) {
    1603     $stylesheet = isset( $stylesheet ) ? $stylesheet : $template;
    1604     return admin_url( 'admin.php' ) . '?customize=on&template=' . $template . '&stylesheet=' . $stylesheet;
    1605 }
    1606 
    1607 /**
    1608  * Prints an href attribute to load the theme customizer.
    1609  *
    1610  * @since 3.4.0
    1611  */
    1612 function wp_customize_href( $template, $stylesheet = null ) {
    1613     $link = wp_customize_url( $template, $stylesheet );
    1614     return 'href="' . esc_url( $link ) . '"';
    1615 }
     1602function wp_customize_url( $stylesheet, $template ) {
     1603    return esc_url( admin_url( 'admin.php' ) . '?customize=on&template=' . $template . '&stylesheet=' . $stylesheet );
     1604}
Note: See TracChangeset for help on using the changeset viewer.