Changeset 52362 for trunk/src/wp-includes/widgets.php
- Timestamp:
- 12/13/2021 10:19:21 AM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/widgets.php
r52361 r52362 520 520 * Default 250. 521 521 * @type int|string $id_base Required for multi-widgets, i.e widgets that allow multiple instances such as the 522 * text widget. The widget idwill end up looking like `{$id_base}-{$unique_number}`.522 * text widget. The widget ID will end up looking like `{$id_base}-{$unique_number}`. 523 523 * } 524 524 * @param mixed ...$params Optional additional parameters to pass to the callback function when it's called. … … 1917 1917 * @since 5.8.0 1918 1918 * 1919 * @param string $widget_id The widget idto look for.1920 * @return string|null The found sidebar's id, or null if it was not found.1919 * @param string $widget_id The widget ID to look for. 1920 * @return string|null The found sidebar's ID, or null if it was not found. 1921 1921 */ 1922 1922 function wp_find_widgets_sidebar( $widget_id ) { … … 1937 1937 * @since 5.8.0 1938 1938 * 1939 * @param string $widget_id The widget idto assign.1940 * @param string $sidebar_id The sidebar idto assign to. If empty, the widget won't be added to any sidebar.1939 * @param string $widget_id The widget ID to assign. 1940 * @param string $sidebar_id The sidebar ID to assign to. If empty, the widget won't be added to any sidebar. 1941 1941 */ 1942 1942 function wp_assign_widget_to_sidebar( $widget_id, $sidebar_id ) { … … 1947 1947 if ( $widget_id === $maybe_widget_id && $sidebar_id !== $maybe_sidebar_id ) { 1948 1948 unset( $sidebars[ $maybe_sidebar_id ][ $i ] ); 1949 // We could technically break 2 here, but continue looping in case the idis duplicated.1949 // We could technically break 2 here, but continue looping in case the ID is duplicated. 1950 1950 continue 2; 1951 1951 }
Note: See TracChangeset
for help on using the changeset viewer.