WordPress.org

Make WordPress Core


Ignore:
Timestamp:
09/04/2016 04:08:11 AM (5 years ago)
Author:
SergeyBiryukov
Message:

Script Loader: Correct default value for $src in wp_enqueue_script() and wp_enqueue_style().

Props Frank Klein for initial patch.
See #37770.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/functions.wp-styles.php

    r37985 r38519  
    152152 * @param string           $handle Name of the stylesheet. Should be unique.
    153153 * @param string           $src    Full URL of the stylesheet, or path of the stylesheet relative to the WordPress root directory.
     154 *                                 Default empty.
    154155 * @param array            $deps   Optional. An array of registered stylesheet handles this stylesheet depends on. Default empty array.
    155156 * @param string|bool|null $ver    Optional. String specifying stylesheet version number, if it has one, which is added to the URL
     
    161162 *                                 '(orientation: portrait)' and '(max-width: 640px)'.
    162163 */
    163 function wp_enqueue_style( $handle, $src = false, $deps = array(), $ver = false, $media = 'all' ) {
     164function wp_enqueue_style( $handle, $src = '', $deps = array(), $ver = false, $media = 'all' ) {
    164165    _wp_scripts_maybe_doing_it_wrong( __FUNCTION__ );
    165166
Note: See TracChangeset for help on using the changeset viewer.