Index: template-functions.php
===================================================================
--- template-functions.php	(revision 998)
+++ template-functions.php	(working copy)
@@ -284,25 +284,37 @@
 	return 'stats-page' == bb_get_location();
 }
 
-function bb_title() {
-	echo apply_filters( 'bb_title', bb_get_title() );
+function bb_title( $args = '' ) {
+	echo apply_filters( 'bb_title', bb_get_title( $args ) );
 }
 
-function bb_get_title() {
+function bb_get_title( $args = '' ) {
+	$defaults = array( 'separator' => ' &laquo; ', 'title' => 'first', 'front' => '' );
+	$args = wp_parse_args( $args, $defaults );
 	$title = '';
-	if ( is_topic() )
-		$title = get_topic_title(). ' &laquo; ';
+	if ( 'last' == $args['title'] )
+		$title .= bb_get_option( 'name' ) . ( ( !is_front() || !empty( $args['front'] ) ) ? $args['separator'] : '' );
+	if ( is_front() && !empty( $args['front'] ) )
+		$title .= $args['front'];
+	elseif ( is_topic() )
+		$title .= get_topic_title();
 	elseif ( is_forum() )
-		$title = get_forum_name() . ' &laquo; ';
-	elseif ( is_bb_tags() )
-		$title = ( is_bb_tag() ? wp_specialchars( bb_get_tag_name() ) . ' &laquo; ' : '' ) . __('Tags') . ' &laquo; ';
+		$title .= get_forum_name();
+	elseif ( is_bb_tags() ) {
+		if ( 'last' == $args['title'] )
+			$title .= __('Tags')  . $args['separator'];
+		$title .= ( is_bb_tag() ? wp_specialchars( bb_get_tag_name() ) : '' );
+		if ( 'last' != $args['title'] )
+			$title .= $args['separator'] . __('Tags');
+	}
 	elseif ( is_bb_profile() )
-		$title = get_user_name() . ' &laquo; ';
+		$title .= get_user_name();
 	elseif ( is_view() )
-		$title = get_view_name() . ' &laquo; ';
+		$title .= get_view_name();
 	if ( $st = bb_get_option( 'static_title' ) )
-		$title = $st;
-	$title .= bb_get_option( 'name' );
+		$title .= $st;
+	if ( 'first' == $args['title'] )
+		$title .= ( ( !is_front() || !empty( $args['front'] ) ) ? $args['separator'] : '' ) . bb_get_option( 'name' );
 	return apply_filters( 'bb_get_title', $title );
 }
 

