Changeset 47963 for branches/5.1/src/wp-admin/includes/misc.php
- Timestamp:
- 06/10/2020 06:18:25 PM (5 years ago)
- Location:
- branches/5.1
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/5.1
- Property svn:mergeinfo changed
/trunk merged: 47948-47951
- Property svn:mergeinfo changed
-
branches/5.1/src/wp-admin/includes/misc.php
r44789 r47963 640 640 break; 641 641 default: 642 if ( '_page' === substr( $option, -5 ) || 'layout_columns' === $option ) { 643 /** 644 * Filters a screen option value before it is set. 645 * 646 * The filter can also be used to modify non-standard [items]_per_page 647 * settings. See the parent function for a full list of standard options. 648 * 649 * Returning false to the filter will skip saving the current option. 650 * 651 * @since 2.8.0 652 * @since 5.4.2 Only applied to options ending with '_page', 653 * or the 'layout_columns' option. 654 * 655 * @see set_screen_options() 656 * 657 * @param bool $keep Whether to save or skip saving the screen option value. 658 * Default false. 659 * @param string $option The option name. 660 * @param int $value The number of rows to use. 661 */ 662 $value = apply_filters( 'set-screen-option', false, $option, $value ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores 663 } 664 642 665 /** 643 666 * Filters a screen option value before it is set. 644 667 * 645 * The filter can also be used to modify non-standard [items]_per_page 646 * settings. See the parent function for a full list of standard options. 668 * The dynamic portion of the hook, `$option`, refers to the option name. 647 669 * 648 670 * Returning false to the filter will skip saving the current option. 649 671 * 650 * @since 2.8.0672 * @since 5.4.2 651 673 * 652 674 * @see set_screen_options() 653 675 * 654 * @param bool $keep Whether to save or skip saving the screen option value. Default false. 655 * @param string $option The option name. 656 * @param int $value The number of rows to use. 676 * @param bool $keep Whether to save or skip saving the screen option value. 677 * Default false. 678 * @param string $option The option name. 679 * @param int $value The number of rows to use. 657 680 */ 658 $value = apply_filters( 'set-screen-option', false, $option, $value );681 $value = apply_filters( "set_screen_option_{$option}", false, $option, $value ); 659 682 660 683 if ( false === $value ) {
Note: See TracChangeset
for help on using the changeset viewer.