Browse Source

! Rejig the spacing on extra_before and extra_after items so the theme controls them rather than the source and more importantly, so that the spacing can be fixed for IE9 and Chrome being silly.

Signed-off-by: Peter Spicer <[email protected]>
Peter Spicer 10 years ago
parent
commit
f006ba737d

+ 1 - 1
Sources/Display.php

@@ -519,7 +519,7 @@ function Display()
 	if (!empty($context['link_moderators']))
 	{
 		// And show it after the board's name.
-		$context['linktree'][count($context['linktree']) - 2]['extra_after'] = '<span class="board_moderators"> (' . (count($context['link_moderators']) == 1 ? $txt['moderator'] : $txt['moderators']) . ': ' . implode(', ', $context['link_moderators']) . ')</span>';
+		$context['linktree'][count($context['linktree']) - 2]['extra_after'] = '<span class="board_moderators">(' . (count($context['link_moderators']) == 1 ? $txt['moderator'] : $txt['moderators']) . ': ' . implode(', ', $context['link_moderators']) . ')</span>';
 	}
 
 	// Information about the current topic...

+ 1 - 1
Sources/Memberlist.php

@@ -328,7 +328,7 @@ function MLAll()
 	$context['linktree'][] = array(
 		'url' => $scripturl . '?action=mlist;sort=' . $_REQUEST['sort'] . ';start=' . $_REQUEST['start'],
 		'name' => &$context['page_title'],
-		'extra_after' => ' (' . sprintf($txt['of_total_members'], $context['num_members']) . ')'
+		'extra_after' => '(' . sprintf($txt['of_total_members'], $context['num_members']) . ')'
 	);
 
 	$limit = $_REQUEST['start'];

+ 1 - 1
Sources/MessageIndex.php

@@ -128,7 +128,7 @@ function MessageIndex()
 	// Now we tack the info onto the end of the linktree
 	if (!empty($context['link_moderators']))
 	{
-	 	$context['linktree'][count($context['linktree']) - 1]['extra_after'] = '<span class="board_moderators"> (' . (count($context['link_moderators']) == 1 ? $txt['moderator'] : $txt['moderators']) . ': ' . implode(', ', $context['link_moderators']) . ')</span>';
+	 	$context['linktree'][count($context['linktree']) - 1]['extra_after'] = '<span class="board_moderators">(' . (count($context['link_moderators']) == 1 ? $txt['moderator'] : $txt['moderators']) . ': ' . implode(', ', $context['link_moderators']) . ')</span>';
 	}
 
 	// Mark current and parent boards as seen.

+ 3 - 3
Sources/Post.php

@@ -1022,8 +1022,8 @@ function Post($post_errors = array())
 		$context['linktree'][] = array(
 			'url' => $scripturl . '?topic=' . $topic . '.' . $_REQUEST['start'],
 			'name' => $form_subject,
-			'extra_before' => '<span><strong class="nav">' . $context['page_title'] . ' ( </strong></span>',
-			'extra_after' => '<span><strong class="nav"> )</strong></span>'
+			'extra_before' => '<span><strong class="nav">' . $context['page_title'] . ' (</strong></span>',
+			'extra_after' => '<span><strong class="nav">)</strong></span>'
 		);
 
 	// Give wireless a linktree url to the post screen, so that they can switch to full version.
@@ -2031,7 +2031,7 @@ function Post2()
 		$context['linktree'][] = array(
 			'url' => $scripturl . '?topic=' . $topic . '.0',
 			'name' => $_POST['subject'],
-			'extra_before' => !empty($settings['linktree_inline']) ? $txt['topic'] . ': ' : ''
+			'extra_before' => !empty($settings['linktree_inline']) ? $txt['topic'] . ':' : ''
 		);
 
 		if (isset($_REQUEST['msg']))

+ 2 - 2
Themes/default/index.template.php

@@ -425,7 +425,7 @@ function theme_linktree($force_show = false)
 
 		// Show something before the link?
 		if (isset($tree['extra_before']))
-			echo $tree['extra_before'];
+			echo $tree['extra_before'], ' ';
 
 		// Show the link, including a URL if it should have one.
 		echo $settings['linktree_link'] && isset($tree['url']) ? '
@@ -433,7 +433,7 @@ function theme_linktree($force_show = false)
 
 		// Show something after the link...?
 		if (isset($tree['extra_after']))
-			echo $tree['extra_after'];
+			echo ' ', $tree['extra_after'];
 
 		echo '
 			</li>';