Changeset 42611 for trunk/src/wp-includes/class-wp-customize-nav-menus.php
- Timestamp:
- 01/29/2018 10:09:55 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-wp-customize-nav-menus.php
r42343 r42611 382 382 'object_id' => intval( $term->term_id ), 383 383 'url' => get_term_link( intval( $term->term_id ), $term->taxonomy ), 384 ); 385 } 386 } 387 388 // Add "Home" link if search term matches. Treat as a page, but switch to custom on add. 389 if ( isset( $args['s'] ) ) { 390 $title = _x( 'Home', 'nav menu home label' ); 391 $matches = function_exists( 'mb_stripos' ) ? false !== mb_stripos( $title, $args['s'] ) : false !== stripos( $title, $args['s'] ); 392 if ( $matches ) { 393 $items[] = array( 394 'id' => 'home', 395 'title' => $title, 396 'type' => 'custom', 397 'type_label' => __( 'Custom Link' ), 398 'object' => '', 399 'url' => home_url(), 384 400 ); 385 401 }
Note: See TracChangeset
for help on using the changeset viewer.