Advertisement
Guest User

r-a-y

a guest
Aug 24th, 2010
271
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function my_add_forum_topic_to_page_title( $title ) {
  2. global $bp;
  3.  
  4. if ( $bp->current_action == 'forum' && $bp->action_variables[0] == 'topic' ) {
  5. if ( bp_has_forum_topic_posts() ) {
  6. $topic_title = bp_get_the_topic_title();
  7. $title = $topic_title . ' | '. $bp->bp_options_title . ' | ' . get_bloginfo( $name );
  8. }
  9. }
  10. return $title;
  11. }
  12. add_filter( 'bp_page_title', 'my_add_forum_topic_to_page_title' );
Advertisement
RAW Paste Data Copied
Advertisement