Last active
May 5, 2018 07:20
-
-
Save JeffCleverley/ce3887d3cc7fa326ee127e36d210654b to your computer and use it in GitHub Desktop.
This file contains 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( 'toolset_build_intermediary_post_title', 'make_descriptive_intermediary_post_titles', 11, 4 ); | |
function make_descriptive_intermediary_post_titles( $post_title, $relationship_slug, $parent_id, $child_id ){ | |
$parent_title = get_the_title( $parent_id ); | |
$child_title = get_the_title( $child_id ); | |
return $relationship_slug . ': ' . $child_title . ' in ' . $parent_title; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment