Changeset 12369 for sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-support/functions.php
- Timestamp:
- 01/26/2023 04:23:09 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-support/functions.php
r12321 r12369 175 175 } 176 176 add_filter( 'bbp_before_get_breadcrumb_parse_args', 'wporg_support_breadcrumb' ); 177 178 add_filter( 179 'bbp_breadcrumbs', 180 /** 181 * Filters the breadcrumbs to replace the home URL with the forums page. 182 */ 183 function( $crumbs ) { 184 foreach ( $crumbs as $i => $link ) { 185 if ( str_contains( $link, 'bbp-breadcrumb-home' ) ) { 186 $crumbs[ $i ] = str_replace( home_url(), home_url( '/forums/' ), $link ); 187 } 188 } 189 return $crumbs; 190 }, 191 10, 192 2 193 ); 177 194 178 195 /**
Note: See TracChangeset
for help on using the changeset viewer.