Created
January 17, 2026 00:21
-
-
Save wplit/f89d03a0545f7451ad3ded397d791862 to your computer and use it in GitHub Desktop.
add new breadcrunk link to breadcrumbs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_filter( 'bricksextras/breadcrumbs/', function( $crumbs ) { | |
| $crumbPosition = 1; | |
| $url = 'https://kevinc366.sg-host.com/tournaments/'; | |
| $text = 'Tournaments'; | |
| /* if single event, add new breadcrumb */ | |
| if ( is_singular('event') ) { | |
| $newCrumb = \BricksExtras\Helpers::breadcrumb_item($url,$text); | |
| array_splice($crumbs, $crumbPosition, 0, $newCrumb); | |
| } | |
| return $crumbs; | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment