Changeset 4536 for trunk/bp-forums/bp-forums-filters.php
- Timestamp:
- 06/19/2011 05:29:51 PM (15 years ago)
- File:
-
- 1 edited
-
trunk/bp-forums/bp-forums-filters.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-forums/bp-forums-filters.php
r4301 r4536 95 95 * 96 96 * @global object $bp 97 * @param string $title 97 * @param string $title New page title; see bp_modify_page_title() 98 * @param string $title Original page title 99 * @param string $sep How to separate the various items within the page title. 100 * @param string $seplocation Direction to display title 98 101 * @return string 99 */ 100 function bp_forums_add_forum_topic_to_page_title( $title ) { 102 * @see bp_modify_page_title() 103 */ 104 function bp_forums_add_forum_topic_to_page_title( $title, $original_title, $sep, $seplocation ) { 101 105 global $bp; 102 106 103 107 if ( $bp->current_action == 'forum' && !empty( $bp->action_variables[0] ) && 'topic' == $bp->action_variables[0] ) 104 108 if ( bp_has_forum_topic_posts() ) 105 $title .= ' | ' . bp_get_the_topic_title();109 $title .= bp_get_the_topic_title() . " $sep "; 106 110 107 111 return $title; 108 112 } 109 add_filter( 'bp_ page_title', 'bp_forums_add_forum_topic_to_page_title');113 add_filter( 'bp_modify_page_title', 'bp_forums_add_forum_topic_to_page_title', 9, 4 ); 110 114 111 115 /**
Note: See TracChangeset
for help on using the changeset viewer.