Changeset 46394
- Timestamp:
- 10/05/2019 12:39:04 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/theme.php
r46392 r46394 906 906 * 907 907 * If the modification name does not exist, then the $default will be passed 908 * through {@link https://secure.php.net/sprintf sprintf()} PHP function with the first909 * string the template directory URI and the second string the stylesheet910 * directory URI.908 * through {@link https://secure.php.net/sprintf sprintf()} PHP function with 909 * the template directory URI as the first string and the stylesheet directory URI 910 * as the second string. 911 911 * 912 912 * @since 2.1.0 913 913 * 914 * @param string $name Theme modification name.915 * @param bool|string $default916 * @return mixed 914 * @param string $name Theme modification name. 915 * @param string|false $default Optional. Theme modification default value. Default false. 916 * @return mixed Theme modification value. 917 917 */ 918 918 function get_theme_mod( $name, $default = false ) { … … 923 923 * Filters the theme modification, or 'theme_mod', value. 924 924 * 925 * The dynamic portion of the hook name, `$name`, refers to 926 * the key name of the modification array. For example, 927 * 'header_textcolor', 'header_image', and so on depending 928 * on the theme options. 925 * The dynamic portion of the hook name, `$name`, refers to the key name 926 * of the modification array. For example, 'header_textcolor', 'header_image', 927 * and so on depending on the theme options. 929 928 * 930 929 * @since 2.2.0 … … 956 955 957 956 /** 958 * Filters the theme mod value on save.959 * 960 * The dynamic portion of the hook name, `$name`, refers to the key name of961 * the modification array. For example, 'header_textcolor', 'header_image',957 * Filters the theme modification, or 'theme_mod', value on save. 958 * 959 * The dynamic portion of the hook name, `$name`, refers to the key name 960 * of the modification array. For example, 'header_textcolor', 'header_image', 962 961 * and so on depending on the theme options. 963 962 * 964 963 * @since 3.9.0 965 964 * 966 * @param string $value The new value of the theme mod .967 * @param string $old_value The current value of the theme mod .965 * @param string $value The new value of the theme modification. 966 * @param string $old_value The current value of the theme modification. 968 967 */ 969 968 $mods[ $name ] = apply_filters( "pre_set_theme_mod_{$name}", $value, $old_value );
Note: See TracChangeset
for help on using the changeset viewer.