Browse Source

Merge branch 'release-2.1' of https://github.com/SimpleMachines/SMF2.1

emanuele 12 years ago
parent
commit
8887bdd079
70 changed files with 815 additions and 795 deletions
  1. 12 1
      README.md
  2. 0 3
      Sources/Admin.php
  3. 10 2
      Sources/Class-BrowserDetect.php
  4. 1 0
      Sources/Logging.php
  5. 4 2
      Sources/ManageLanguages.php
  6. 10 3
      Sources/ManageMaintenance.php
  7. 0 4
      Sources/ManageMembergroups.php
  8. 0 2
      Sources/ManageMembers.php
  9. 51 46
      Sources/ManageSearch.php
  10. 4 4
      Sources/Memberlist.php
  11. 0 3
      Sources/ModerationCenter.php
  12. 1 1
      Sources/Packages.php
  13. 3 3
      Sources/Post.php
  14. 2 0
      Sources/ScheduledTasks.php
  15. 1 1
      Sources/Search.php
  16. 53 58
      Sources/SearchAPI-Fulltext.php
  17. 3 3
      Sources/Security.php
  18. 4 4
      Sources/Subs-Auth.php
  19. 2 0
      Sources/Subs-List.php
  20. 4 0
      Sources/Subs-Menu.php
  21. 5 2
      Sources/Subs.php
  22. 1 1
      Sources/Who.php
  23. 6 4
      Themes/default/Admin.template.php
  24. 6 4
      Themes/default/Errors.template.php
  25. 1 3
      Themes/default/GenericMenu.template.php
  26. 3 2
      Themes/default/Login.template.php
  27. 3 8
      Themes/default/ManageAttachments.template.php
  28. 1 5
      Themes/default/ManageBans.template.php
  29. 1 3
      Themes/default/ManageCalendar.template.php
  30. 38 42
      Themes/default/ManageLanguages.template.php
  31. 6 9
      Themes/default/ManageMaintenance.template.php
  32. 2 6
      Themes/default/ManageMembergroups.template.php
  33. 1 1
      Themes/default/ManageMembers.template.php
  34. 4 5
      Themes/default/ManageNews.template.php
  35. 12 15
      Themes/default/ManagePaid.template.php
  36. 9 18
      Themes/default/ManagePermissions.template.php
  37. 1 2
      Themes/default/ManageScheduledTasks.template.php
  38. 8 19
      Themes/default/ManageSearch.template.php
  39. 9 17
      Themes/default/ManageSmileys.template.php
  40. 3 2
      Themes/default/Memberlist.template.php
  41. 5 9
      Themes/default/MessageIndex.template.php
  42. 9 18
      Themes/default/ModerationCenter.template.php
  43. 0 1
      Themes/default/MoveTopic.template.php
  44. 19 33
      Themes/default/Packages.template.php
  45. 7 11
      Themes/default/PersonalMessage.template.php
  46. 1 2
      Themes/default/Poll.template.php
  47. 4 3
      Themes/default/Profile.template.php
  48. 1 1
      Themes/default/Recent.template.php
  49. 27 22
      Themes/default/Register.template.php
  50. 12 11
      Themes/default/Reminder.template.php
  51. 19 18
      Themes/default/Search.template.php
  52. 10 12
      Themes/default/SendTopic.template.php
  53. 73 73
      Themes/default/SplitTopics.template.php
  54. 24 41
      Themes/default/Themes.template.php
  55. 19 6
      Themes/default/css/index.css
  56. 19 19
      Themes/default/languages/Admin.english.php
  57. 7 7
      Themes/default/languages/ManageMail.english.php
  58. 4 4
      Themes/default/languages/ManageMaintenance.english.php
  59. 10 10
      Themes/default/languages/ManageMembers.english.php
  60. 1 1
      Themes/default/languages/ManageSettings.english.php
  61. 13 13
      Themes/default/languages/ManageSmileys.english.php
  62. 9 9
      Themes/default/languages/ModerationCenter.english.php
  63. 13 13
      Themes/default/languages/Packages.english.php
  64. 34 34
      Themes/default/languages/PersonalMessage.english.php
  65. 23 23
      Themes/default/languages/Post.english.php
  66. 1 0
      Themes/default/languages/index.english.php
  67. 1 1
      Themes/default/scripts/jquery.sceditor.js
  68. 2 4
      Themes/default/scripts/script.js
  69. 5 5
      Themes/default/scripts/smf_jquery_plugins.js
  70. 158 83
      Themes/default/scripts/topic.js

+ 12 - 1
README.md

@@ -9,9 +9,14 @@ Contributions to documentation are licensed under [CC-by-SA 3](http://creativeco
 
 Feel free to fork this repository and make your desired changes.
 
-Please see the [Developer's Certificate of Origin](https://github.com/Spuds/playpen/blob/master/DCO.txt) in the repository:
+Please see the [Developer's Certificate of Origin](https://github.com/SimpleMachines/SMF2.1/blob/master/DCO.txt) in the repository:
 by signing off your contributions, you acknowledge that you can and do license your submissions under the license of the project.
 
+######Branches organization:
+* ***master*** - is the main branch, only used to merge in a "final release"
+* ***development*** - is the branch where the development of the "next" version/s happens
+* ***release-2.1*** - is the branch where bug fixes for the version 2.1 are applied
+
 ######How to contribute:
 * fork the repository. If you are not used to Github, please check out [fork a repository](http://help.github.com/fork-a-repo).
 * branch your repository, to commit the desired changes.
@@ -19,5 +24,11 @@ by signing off your contributions, you acknowledge that you can and do license y
  * an easy way to do so, is to define an alias for the git commit command, which includes -s switch (reference: [How to create Git aliases](http://githacks.com/post/1168909216/how-to-create-git-aliases))
 * send a pull request to us.
 
+######How to submit a pull request:
+* If you want to send a bug fix for the version 2.1, send it to the branch ***release-2.1***
+* If you want to send a new feature, use the branch ***development***
+* You should never send any pull request against the master branch
+For more informations, the ideal branching we would like to follow is the one described in [this article](http://nvie.com/posts/a-successful-git-branching-model/)
+
 Finally, feel free to play around. That's what we're doing. ;)
 

+ 0 - 3
Sources/Admin.php

@@ -457,9 +457,6 @@ function AdminMain()
 		}
 	}
 
-	// Let them modify admin areas easily.
-	call_integration_hook('integrate_admin_areas', array(&$admin_areas));
-
 	// Make sure the administrator has a valid session...
 	validateSession();
 

+ 10 - 2
Sources/Class-BrowserDetect.php

@@ -357,14 +357,17 @@ class browser_detector
 	function fillInformation()
 	{
 		$this->_browsers += array(
-			'is_webkit' => false,
+			'is_opera' => false,
 			'is_opera6' => false,
 			'is_opera7' => false,
 			'is_opera8' => false,
 			'is_opera9' => false,
 			'is_opera10' => false,
-			'is_ie4' => false,
+			'is_webkit' => false,
 			'is_mac_ie' => false,
+			'is_web_tv' => false,
+			'is_konqueror' => false,
+			'is_firefox' => false,
 			'is_firefox1' => false,
 			'is_firefox2' => false,
 			'is_firefox3' => false,
@@ -372,12 +375,17 @@ class browser_detector
 			'is_android' => false,
 			'is_chrome' => false,
 			'is_safari' => false,
+			'is_gecko'  => false,
 			'is_ie8' => false,
 			'is_ie7' => false,
 			'is_ie6' => false,
 			'is_ie5.5' => false,
 			'is_ie5' => false,
+			'is_ie' => false,
+			'is_ie4' => false,
 			'ie_standards_fix' => false,
+			'needs_size_fix' => false,
+			'possibly_robot' => false,
 		);
 	}
 }

+ 1 - 0
Sources/Logging.php

@@ -247,6 +247,7 @@ function displayDebug()
 	', $txt['debug_subtemplates'], count($context['debug']['sub_templates']), ': <em>', implode('</em>, <em>', $context['debug']['sub_templates']), '</em>.<br />
 	', $txt['debug_language_files'], count($context['debug']['language_files']), ': <em>', implode('</em>, <em>', $context['debug']['language_files']), '</em>.<br />
 	', $txt['debug_stylesheets'], count($context['debug']['sheets']), ': <em>', implode('</em>, <em>', $context['debug']['sheets']), '</em>.<br />
+	', $txt['debug_hooks'], empty($context['debug']['hooks']) ? 0 : count($context['debug']['hooks']) . ' (<a href="javascript:void(0);" onclick="document.getElementById(\'debug_hooks\').style.display = \'inline\'; this.style.display = \'none\'; return false;">', $txt['debug_show'], '</a><span id="debug_hooks" style="display: none;"><em>' . implode('</em>, <em>', $context['debug']['hooks']), '</em></span>)', '<br />
 	', $txt['debug_files_included'], count($files), ' - ', round($total_size / 1024), $txt['debug_kb'], ' (<a href="javascript:void(0);" onclick="document.getElementById(\'debug_include_info\').style.display = \'inline\'; this.style.display = \'none\'; return false;">', $txt['debug_show'], '</a><span id="debug_include_info" style="display: none;"><em>', implode('</em>, <em>', $files), '</em></span>)<br />';
 
 	// What tokens are active?

+ 4 - 2
Sources/ManageLanguages.php

@@ -147,9 +147,11 @@ function list_getLanguagesList()
 	require_once($sourcedir . '/Class-Package.php');
 	$language_list = new xmlArray(fetch_web_data($url), true);
 
-	// Check it exists.
-	if (!$language_list->exists('languages/language'))
+	// Check that the site responded and that the language exists.
+	if (!$language_list->exists('languages'))
 		$context['smf_error'] = 'no_response';
+	elseif (!$language_list->exists('languages/language'))
+		$context['smf_error'] = 'no_files';
 	else
 	{
 		$language_list = $language_list->path('languages[0]');

+ 10 - 3
Sources/ManageMaintenance.php

@@ -471,8 +471,15 @@ function ConvertUtf8()
 		if ($db_character_set === 'utf8' && !empty($modSettings['global_character_set']) && $modSettings['global_character_set'] === 'UTF-8')
 			fatal_lang_error('utf8_already_utf8');
 
+		// Detect whether a fulltext index is set.
+		db_extend('search');
+		if ($smcFunc['db_search_support']('fulltext'))
+		{
+			require_once($sourcedir . '/ManageSearch.php');
+			detectFulltextIndex();
+		}
 		// Cannot do conversion if using a fulltext index
-		if (!empty($modSettings['search_index']) && $modSettings['search_index'] == 'fulltext')
+		if (!empty($modSettings['search_index']) && $modSettings['search_index'] == 'fulltext' || !empty($context['fulltext_index']))
 			fatal_lang_error('utf8_cannot_convert_fulltext');
 
 		// Grab the character set from the default language file.
@@ -675,9 +682,9 @@ function ConvertUtf8()
 					foreach ($columns as $column)
 					{
 						$updates_blob .= '
-							CHANGE COLUMN ' . $column['Field'] . ' ' . $column['Field'] . ' ' . strtr($column['Type'], array('text' => 'blob', 'char' => 'binary')) . ($column['Null'] === 'YES' ? ' NULL' : ' NOT NULL') . (strpos($column['Type'], 'char') === false ? '' : ' default \'' . $column['Default'] . '\'') . ',';
+							CHANGE COLUMN `' . $column['Field'] . '` `' . $column['Field'] . '` ' . strtr($column['Type'], array('text' => 'blob', 'char' => 'binary')) . ($column['Null'] === 'YES' ? ' NULL' : ' NOT NULL') . (strpos($column['Type'], 'char') === false ? '' : ' default \'' . $column['Default'] . '\'') . ',';
 						$updates_text .= '
-							CHANGE COLUMN ' . $column['Field'] . ' ' . $column['Field'] . ' ' . $column['Type'] . ' CHARACTER SET ' . $charsets[$_POST['src_charset']] . ($column['Null'] === 'YES' ? '' : ' NOT NULL') . (strpos($column['Type'], 'char') === false ? '' : ' default \'' . $column['Default'] . '\'') . ',';
+							CHANGE COLUMN `' . $column['Field'] . '` `' . $column['Field'] . '` ' . $column['Type'] . ' CHARACTER SET ' . $charsets[$_POST['src_charset']] . ($column['Null'] === 'YES' ? '' : ' NOT NULL') . (strpos($column['Type'], 'char') === false ? '' : ' default \'' . $column['Default'] . '\'') . ',';
 					}
 				}
 			}

+ 0 - 4
Sources/ManageMembergroups.php

@@ -196,8 +196,6 @@ function MembergroupIndex()
 		),
 	);
 
-	call_integration_hook('integrate_modify_regular_groups', array(&$listOptions));
-
 	require_once($sourcedir . '/Subs-List.php');
 	createList($listOptions);
 
@@ -309,8 +307,6 @@ function MembergroupIndex()
 		),
 	);
 
-	call_integration_hook('integrate_modify_post_groups', array(&$listOptions));
-
 	createList($listOptions);
 }
 

+ 0 - 2
Sources/ManageMembers.php

@@ -609,8 +609,6 @@ function ViewMemberlist()
 	if (!allowedTo('profile_remove_any'))
 		unset($listOptions['cols']['check'], $listOptions['form'], $listOptions['additional_rows']);
 
-	call_integration_hook('integrate_view_members_list', array(&$listOptions));
-
 	require_once($sourcedir . '/Subs-List.php');
 	createList($listOptions);
 

+ 51 - 46
Sources/ManageSearch.php

@@ -216,52 +216,7 @@ function EditSearchMethod()
 
 	// Detect whether a fulltext index is set.
 	if ($context['supports_fulltext'])
-	{
-		$request = $smcFunc['db_query']('', '
-			SHOW INDEX
-			FROM {db_prefix}messages',
-			array(
-			)
-		);
-		$context['fulltext_index'] = '';
-		if ($request !== false || $smcFunc['db_num_rows']($request) != 0)
-		{
-			while ($row = $smcFunc['db_fetch_assoc']($request))
-				if ($row['Column_name'] == 'body' && (isset($row['Index_type']) && $row['Index_type'] == 'FULLTEXT' || isset($row['Comment']) && $row['Comment'] == 'FULLTEXT'))
-					$context['fulltext_index'][] = $row['Key_name'];
-			$smcFunc['db_free_result']($request);
-
-			if (is_array($context['fulltext_index']))
-				$context['fulltext_index'] = array_unique($context['fulltext_index']);
-		}
-
-		if (preg_match('~^`(.+?)`\.(.+?)$~', $db_prefix, $match) !== 0)
-			$request = $smcFunc['db_query']('', '
-				SHOW TABLE STATUS
-				FROM {string:database_name}
-				LIKE {string:table_name}',
-				array(
-					'database_name' => '`' . strtr($match[1], array('`' => '')) . '`',
-					'table_name' => str_replace('_', '\_', $match[2]) . 'messages',
-				)
-			);
-		else
-			$request = $smcFunc['db_query']('', '
-				SHOW TABLE STATUS
-				LIKE {string:table_name}',
-				array(
-					'table_name' => str_replace('_', '\_', $db_prefix) . 'messages',
-				)
-			);
-
-		if ($request !== false)
-		{
-			while ($row = $smcFunc['db_fetch_assoc']($request))
-				if ((isset($row['Type']) && strtolower($row['Type']) != 'myisam') || (isset($row['Engine']) && strtolower($row['Engine']) != 'myisam'))
-					$context['cannot_create_fulltext'] = true;
-			$smcFunc['db_free_result']($request);
-		}
-	}
+		detectFulltextIndex();
 
 	if (!empty($_REQUEST['sa']) && $_REQUEST['sa'] == 'createfulltext')
 	{
@@ -790,4 +745,54 @@ function loadSearchAPIs()
 	return $apis;
 }
 
+function detectFulltextIndex()
+{
+	global $smcFunc, $context, $db_prefix;
+
+	$request = $smcFunc['db_query']('', '
+		SHOW INDEX
+		FROM {db_prefix}messages',
+		array(
+		)
+	);
+	$context['fulltext_index'] = '';
+	if ($request !== false || $smcFunc['db_num_rows']($request) != 0)
+	{
+		while ($row = $smcFunc['db_fetch_assoc']($request))
+			if ($row['Column_name'] == 'body' && (isset($row['Index_type']) && $row['Index_type'] == 'FULLTEXT' || isset($row['Comment']) && $row['Comment'] == 'FULLTEXT'))
+				$context['fulltext_index'][] = $row['Key_name'];
+		$smcFunc['db_free_result']($request);
+
+		if (is_array($context['fulltext_index']))
+			$context['fulltext_index'] = array_unique($context['fulltext_index']);
+	}
+
+	if (preg_match('~^`(.+?)`\.(.+?)$~', $db_prefix, $match) !== 0)
+		$request = $smcFunc['db_query']('', '
+			SHOW TABLE STATUS
+			FROM {string:database_name}
+			LIKE {string:table_name}',
+			array(
+				'database_name' => '`' . strtr($match[1], array('`' => '')) . '`',
+				'table_name' => str_replace('_', '\_', $match[2]) . 'messages',
+			)
+		);
+	else
+		$request = $smcFunc['db_query']('', '
+			SHOW TABLE STATUS
+			LIKE {string:table_name}',
+			array(
+				'table_name' => str_replace('_', '\_', $db_prefix) . 'messages',
+			)
+		);
+
+	if ($request !== false)
+	{
+		while ($row = $smcFunc['db_fetch_assoc']($request))
+			if ((isset($row['Type']) && strtolower($row['Type']) != 'myisam') || (isset($row['Engine']) && strtolower($row['Engine']) != 'myisam'))
+				$context['cannot_create_fulltext'] = true;
+		$smcFunc['db_free_result']($request);
+	}
+}
+
 ?>

+ 4 - 4
Sources/Memberlist.php

@@ -603,12 +603,12 @@ function printMemberListRows($request)
 		array(
 		)
 	);
-	list ($MOST_POSTS) = $smcFunc['db_fetch_row']($result);
+	list ($most_posts) = $smcFunc['db_fetch_row']($result);
 	$smcFunc['db_free_result']($result);
 
 	// Avoid division by zero...
-	if ($MOST_POSTS == 0)
-		$MOST_POSTS = 1;
+	if ($most_posts == 0)
+		$most_posts = 1;
 
 	$members = array();
 	while ($row = $smcFunc['db_fetch_assoc']($request))
@@ -624,7 +624,7 @@ function printMemberListRows($request)
 			continue;
 
 		$context['members'][$member] = $memberContext[$member];
-		$context['members'][$member]['post_percent'] = round(($context['members'][$member]['real_posts'] * 100) / $MOST_POSTS);
+		$context['members'][$member]['post_percent'] = round(($context['members'][$member]['real_posts'] * 100) / $most_posts);
 		$context['members'][$member]['registered_date'] = strftime('%Y-%m-%d', $context['members'][$member]['registered_timestamp']);
 	}
 }

+ 0 - 3
Sources/ModerationCenter.php

@@ -154,9 +154,6 @@ function ModerationMain($dont_call = false)
 		),
 	);
 
-	// Let them modify admin areas easily.
-	call_integration_hook('integrate_moderate_areas', array(&$moderation_areas));
-
 	// Make sure the administrator has a valid session...
 	validateSession('moderate');
 

+ 1 - 1
Sources/Packages.php

@@ -1571,7 +1571,7 @@ function list_getPackages($start, $items_per_page, $sort, $params, $installed)
 
 	if (empty($packages))
 		foreach ($context['modification_types'] as $type)
-			$packages[$type] = arra();
+			$packages[$type] = array();
 
 	if ($dir = @opendir($boarddir . '/Packages'))
 	{

+ 3 - 3
Sources/Post.php

@@ -18,7 +18,7 @@ if (!defined('SMF'))
 	die('Hacking attempt...');
 
 /**
- * handles showing the post screen, loading the post to be modified, and loading any post quoted.
+ * Handles showing the post screen, loading the post to be modified, and loading any post quoted.
  *
  * - additionally handles previews of posts.
  * - @uses the Post template and language file, main sub template.
@@ -2045,7 +2045,7 @@ function Post2()
 }
 
 /**
- * handle the announce topic function (action=announce).
+ * Handle the announce topic function (action=announce).
  *
  * checks the topic announcement permissions and loads the announcement template.
  * requires the announce_topic permission.
@@ -2504,7 +2504,7 @@ function getTopic()
 }
 
 /**
- * loads a post an inserts it into the current editing text box.
+ * Loads a post an inserts it into the current editing text box.
  * uses the Post language file.
  * uses special (sadly browser dependent) javascript to parse entities for internationalization reasons.
  * accessed with ?action=quotefast.

+ 2 - 0
Sources/ScheduledTasks.php

@@ -28,6 +28,8 @@ function AutoTask()
 		ReduceMailQueue();
 	else
 	{
+		call_integration_hook('integrate_autotask_include');
+
 		// Select the next task to do.
 		$request = $smcFunc['db_query']('', '
 			SELECT id_task, task, next_time, time_offset, time_regularity, time_unit

+ 1 - 1
Sources/Search.php

@@ -1628,7 +1628,7 @@ function PlushSearch2()
 				if ($_SESSION['search_cache']['num_results'] < $modSettings['search_max_results'] && $numSubjectResults !== 0)
 				{
 					$relevance = '1000 * (';
-					foreach ($main_query['weights'] as $type => $value)
+					foreach ($weight_factors as $type => $value)
 						if (isset($value['results']))
 						{
 							$relevance .= $weight[$type];

+ 53 - 58
Sources/SearchAPI-Fulltext.php

@@ -22,9 +22,6 @@ class fulltext_search
 	public $min_smf_version = 'SMF 2.1 Alpha 1';
 	// Is it supported?
 	public $is_supported = true;
-
-	// Can we do a boolean search - tested on construct.
-	protected $canDoBooleanSearch = false;
 	// What words are banned?
 	protected $bannedWords = array();
 	// What is the minimum word length?
@@ -32,6 +29,10 @@ class fulltext_search
 	// What databases support the fulltext index?
 	protected $supported_databases = array('mysql');
 
+	/**
+	 * fulltext_search::__construct()
+	 *
+	 */
 	public function __construct()
 	{
 		global $smcFunc, $db_connection, $modSettings, $db_type;
@@ -43,14 +44,19 @@ class fulltext_search
 			return;
 		}
 
-		// Some MySQL versions are superior to others :P.
-		$this->canDoBooleanSearch = version_compare($smcFunc['db_server_info']($db_connection), '4.0.1', '>=');
-
 		$this->bannedWords = empty($modSettings['search_banned_words']) ? array() : explode(',', $modSettings['search_banned_words']);
 		$this->min_word_length = $this->_getMinWordLength();
 	}
 
-	// Check whether the method can be performed by this API.
+	/**
+	 * fulltext_search::supportsMethod()
+	 *
+	 * Check whether the method can be performed by this API.
+	 *
+	 * @param mixed $methodName
+	 * @param mixed $query_params
+	 * @return
+	 */
 	public function supportsMethod($methodName, $query_params = null)
 	{
 		switch ($methodName)
@@ -68,7 +74,13 @@ class fulltext_search
 		}
 	}
 
-	// What is the minimum word length full text supports?
+	/**
+	 * fulltext_search::_getMinWordLength()
+	 *
+	 * What is the minimum word length full text supports?
+	 *
+	 * @return
+	 */
 	protected function _getMinWordLength()
 	{
 		global $smcFunc;
@@ -92,7 +104,7 @@ class fulltext_search
 
 		return $min_word_length;
 	}
-
+	
 	/**
 	 * callback function for usort used to sort the fulltext results.
 	 * the order of sorting is: large words, small words, large words that
@@ -103,26 +115,34 @@ class fulltext_search
 	 */
 	public function searchSort($a, $b)
 	{
-		global $modSettings, $excludedWords;
-
-		$x = strlen($a) - (in_array($a, $excludedWords) ? 1000 : 0);
-		$y = strlen($b) - (in_array($b, $excludedWords) ? 1000 : 0);
+		global $modSettings, $excludedWords, $smcFunc;
 
+		$x = $smcFunc['strlen']($a) - (in_array($a, $excludedWords) ? 1000 : 0);
+		$y = $smcFunc['strlen']($b) - (in_array($b, $excludedWords) ? 1000 : 0);
+		
 		return $x < $y ? 1 : ($x > $y ? -1 : 0);
 	}
-
-	// Do we have to do some work with the words we are searching for to prepare them?
+	
+	/**
+	 * fulltext_search::prepareIndexes()
+	 *
+	 * Do we have to do some work with the words we are searching for to prepare them?
+	 *
+	 * @param mixed $word
+	 * @param mixed $wordsSearch
+	 * @param mixed $wordsExclude
+	 * @param mixed $isExcluded
+	 * @return
+	 */
 	public function prepareIndexes($word, &$wordsSearch, &$wordsExclude, $isExcluded)
 	{
 		global $modSettings, $smcFunc;
 
 		$subwords = text2words($word, null, false);
 
-		if (!$this->canDoBooleanSearch && count($subwords) > 1 && empty($modSettings['search_force_index']))
-			$wordsSearch['words'][] = $word;
-		elseif (empty($modSettings['search_force_index']) && $this->canDoBooleanSearch)
+		if (empty($modSettings['search_force_index']))
 		{
-			// A boolean capable search engine and not forced to only use an index, we may use a non index search
+			// A boolean capable search engine and not forced to only use an index, we may use a non indexed search
 			// this is harder on the server so we are restrictive here
 			if (count($subwords) > 1 && preg_match('~[.:@$]~', $word))
 			{
@@ -141,37 +161,21 @@ class fulltext_search
 			}
 		}
 
-		if ($this->canDoBooleanSearch)
-		{
-			$fulltextWord = count($subwords) === 1 ? $word : '"' . $word . '"';
-			$wordsSearch['indexed_words'][] = $fulltextWord;
-			if ($isExcluded)
-				$wordsExclude[] = $fulltextWord;
-		}
-		// Excluded phrases don't benefit from being split into subwords.
-		elseif (count($subwords) > 1 && $isExcluded)
-			return;
-		else
-		{
-			$relyOnIndex = true;
-			foreach ($subwords as $subword)
-			{
-				if (($smcFunc['strlen']($subword) >= $this->min_word_length) && !in_array($subword, $this->bannedWords))
-				{
-					$wordsSearch['indexed_words'][] = $subword;
-					if ($isExcluded)
-						$wordsExclude[] = $subword;
-				}
-				elseif (!in_array($subword, $this->bannedWords))
-					$relyOnIndex = false;
-			}
-
-			if ($this->canDoBooleanSearch && !$relyOnIndex && empty($modSettings['search_force_index']))
-				$wordsSearch['words'][] = $word;
-		}
+		$fulltextWord = count($subwords) === 1 ? $word : '"' . $word . '"';
+		$wordsSearch['indexed_words'][] = $fulltextWord;
+		if ($isExcluded)
+			$wordsExclude[] = $fulltextWord;
 	}
 
-	// Search for indexed words.
+	/**
+	 * fulltext_search::indexedWordQuery()
+	 *
+	 * Search for indexed words.
+	 *
+	 * @param mixed $words
+	 * @param mixed $search_data
+	 * @return
+	 */
 	public function indexedWordQuery($words, $search_data)
 	{
 		global $modSettings, $smcFunc;
@@ -225,7 +229,7 @@ class fulltext_search
 			$query_where[] = 'MATCH (body) AGAINST ({string:body_match})';
 			$query_params['body_match'] = implode(' ', array_diff($words['indexed_words'], $query_params['excluded_index_words']));
 		}
-		elseif ($this->canDoBooleanSearch)
+		else
 		{
 			$query_params['boolean_match'] = '';
 
@@ -240,15 +244,6 @@ class fulltext_search
 			if ($query_params['boolean_match'])
 				$query_where[] = 'MATCH (body) AGAINST ({string:boolean_match} IN BOOLEAN MODE)';
 		}
-		else
-		{
-			$count = 0;
-			foreach ($words['indexed_words'] as $fulltextWord)
-			{
-				$query_where[] = (in_array($fulltextWord, $query_params['excluded_index_words']) ? 'NOT ' : '') . 'MATCH (body) AGAINST ({string:fulltext_match_' . $count . '})';
-				$query_params['fulltext_match_' . $count++] = $fulltextWord;
-			}
-		}
 
 		$ignoreRequest = $smcFunc['db_search_query']('insert_into_log_messages_fulltext', ($smcFunc['db_support_ignore'] ? ( '
 			INSERT IGNORE INTO {db_prefix}' . $search_data['insert_into'] . '

+ 3 - 3
Sources/Security.php

@@ -1022,9 +1022,9 @@ function isAllowedTo($permission, $boards = null)
 
 /**
  * Return the boards a user has a certain (board) permission on. (array(0) if all.)
- * returns a list of boards on which the user is allowed to do the specified permission.
- * Returns an array with only a 0 in it if the user has permission to do this on every board.
- * Returns an empty array if he or she cannot do this on any board.
+ *  - returns a list of boards on which the user is allowed to do the specified permission.
+ *  - returns an array with only a 0 in it if the user has permission to do this on every board.
+ *  - returns an empty array if he or she cannot do this on any board.
  * If check_access is true will also make sure the group has proper access to that board.
  *
  * @param array $permissions

+ 4 - 4
Sources/Subs-Auth.php

@@ -17,7 +17,7 @@ if (!defined('SMF'))
 	die('Hacking attempt...');
 
 /**
- * sets the SMF-style login cookie and session based on the id_member and password passed.
+ * Sets the SMF-style login cookie and session based on the id_member and password passed.
  * - password should be already encrypted with the cookie salt.
  * - logs the user out if id_member is zero.
  * - sets the cookie and session to last the number of seconds specified by cookie_length.
@@ -247,7 +247,7 @@ function adminLogin($type = 'admin')
 }
 
 /**
- * used by the adminLogin() function.
+ * Used by the adminLogin() function.
  * if 'value' is an array, the function is called recursively.
  *
  * @param string $key
@@ -399,7 +399,7 @@ function findMembers($names, $use_wildcards = false, $buddies_only = false, $max
 }
 
 /**
- * called by index.php?action=findmember.
+ * Called by index.php?action=findmember.
  * - is used as a popup for searching members.
  * - uses sub template find_members of the Help template.
  * - also used to add members for PM's sent using wap2/imode protocol.
@@ -471,7 +471,7 @@ function JSMembers()
 }
 
 /**
- * outputs each member name on its own line.
+ * Outputs each member name on its own line.
  * - used by javascript to find members matching the request.
  */
 function RequestMembers()

+ 2 - 0
Sources/Subs-List.php

@@ -31,6 +31,8 @@ function createList($listOptions)
 	assert((empty($listOptions['default_sort_col']) || isset($listOptions['columns'][$listOptions['default_sort_col']])));
 	assert((!isset($listOptions['form']) || isset($listOptions['form']['href'])));
 
+	call_integration_hook('integrate_' . $listOptions['id'], array(&$listOptions));
+
 	// All the context data will be easily accessible by using a reference.
 	$context[$listOptions['id']] = array();
 	$list_context = &$context[$listOptions['id']];

+ 4 - 0
Sources/Subs-Menu.php

@@ -66,6 +66,10 @@ function createMenu($menuData, $menuOptions = array())
 	// What is the general action of this menu (i.e. $scripturl?action=XXXX.
 	$menu_context['current_action'] = isset($menuOptions['action']) ? $menuOptions['action'] : $context['current_action'];
 
+	// Allow extend *any* menu with a single hook
+	if (!empty($menuOptions['action']))
+		call_integration_hook('integrate_' . $menu_context['current_action'] . '_areas', array(&$menuData));
+
 	// What is the current area selected?
 	if (isset($menuOptions['current_area']) || isset($_GET['area']))
 		$menu_context['current_area'] = isset($menuOptions['current_area']) ? $menuOptions['current_area'] : $_GET['area'];

+ 5 - 2
Sources/Subs.php

@@ -3610,7 +3610,7 @@ function create_button($name, $alt, $label = '', $custom = '', $force_use = fals
 /**
  * Empty out the cache in use as best it can
  *
- * it may only remove the files of a certain type (if the $type parameter is given)
+ * It may only remove the files of a certain type (if the $type parameter is given)
  * Type can be user, data or left blank
  * 	- user clears out user data
  *  - data clears out system / opcode data
@@ -4046,7 +4046,10 @@ function smf_seed_generator()
  */
 function call_integration_hook($hook, $parameters = array())
 {
-	global $modSettings, $settings, $boarddir, $sourcedir;
+	global $modSettings, $settings, $boarddir, $sourcedir, $db_show_debug, $context;
+
+	if ($db_show_debug === true)
+		$context['debug']['hooks'][] = $hook;
 
 	$results = array();
 	if (empty($modSettings[$hook]))

+ 1 - 1
Sources/Who.php

@@ -723,7 +723,7 @@ function Credits($in_admin = false)
 		),
 	);
 
-	// support for mods that use the <credits> tag via the package manager
+	// Support for mods that use the <credits> tag via the package manager
 	$context['credits_modifications'] = array();
 	if (($mods = cache_get_data('mods_credits', 86400)) === null)
 	{

+ 6 - 4
Themes/default/Admin.template.php

@@ -296,7 +296,8 @@ function template_credits()
 
 		if (isset($section['posttext']))
 			echo '
-					<hr /><p>', $section['posttext'], '</p>';
+					<hr />
+					<p>', $section['posttext'], '</p>';
 	}
 
 	echo '
@@ -680,7 +681,7 @@ function template_not_done()
 
 	if (!empty($context['substep_enabled']))
 		echo '
-					<div class="progress_bar">
+				<div class="progress_bar">
 					<div class="full_bar">', $context['substep_title'], ' (', $context['substep_continue_percent'], '%)</div>
 					<div class="blue_percent" style="width: ', $context['substep_continue_percent'], '%;">&nbsp;</div>
 				</div>';
@@ -1218,7 +1219,7 @@ function template_admin_search_results()
 						<input type="submit" name="search_go" value="', $txt['admin_search_results_again'], '" class="button_submit" />
 					</form>
 				</object>
-				<img src="' . $settings['images_url'] . '/buttons/search.png" alt="" />&nbsp;', sprintf($txt['admin_search_results_desc'], $context['search_term']), '
+				<img class="icon" src="' . $settings['images_url'] . '/buttons/search.png" alt="" />&nbsp;', sprintf($txt['admin_search_results_desc'], $context['search_term']), '
 			</h3>
 		</div>
 	<div class="windowbg2 generic_list_wrapper">
@@ -1619,7 +1620,8 @@ function template_php_info()
 		}
 		echo '
 		</tbody>
-	</table><br />';
+	</table>
+	<br />';
 	}
 
 	echo '

+ 6 - 4
Themes/default/Errors.template.php

@@ -36,7 +36,9 @@ function template_fatal_error()
 
 	// Show a back button (using javascript.)
 	echo '
-	<div class="centertext"><a href="javascript:history.go(-1)">', $txt['back'], '</a></div>';
+	<div class="centertext">
+		<a class="button_link" style="float:none" href="javascript:history.go(-1)">', $txt['back'], '</a>
+	</div>';
 }
 
 function template_error_log()
@@ -191,14 +193,14 @@ function template_show_file()
 		<link rel="stylesheet" type="text/css" href="', $settings['theme_url'], '/css/index', $context['theme_variant'], '.css?alp21" />
 	</head>
 	<body>
-		<table border="0" cellpadding="0" cellspacing="3">';
+		<table class="errorfile_table">';
 	foreach ($context['file_data']['contents'] as $index => $line)
 	{
-		$line_num = $index+$context['file_data']['min'];
+		$line_num = $index + $context['file_data']['min'];
 		$is_target = $line_num == $context['file_data']['target'];
 		echo '
 			<tr>
-				<td align="right"', $is_target ? ' style="font-weight: bold; border: 1px solid black;border-width: 1px 0 1px 1px;">==&gt;' : '>', $line_num , ':</td>
+				<td align="right"', $is_target ? ' class="current">==&gt;' : '>', $line_num , ':</td>
 				<td style="white-space: nowrap;', $is_target ? ' border: 1px solid black;border-width: 1px 1px 1px 0;':'','">', $line, '</td>
 			</tr>';
 	}

+ 1 - 3
Themes/default/GenericMenu.template.php

@@ -16,11 +16,9 @@ function template_generic_menu_sidebar_above()
 	global $context, $settings, $options, $scripturl, $txt, $modSettings;
 
 	// This is the main table - we need it so we can keep the content to the right of it.
-	// [WIP] Why is there a span id="admin_menu"? #admin_menu is also the div that wraps the drop menu system.
-	// Is this some bonkers leftover span from 2.0 beta days? It has no content and is not listed in the CSS.
 	echo '
 	<div id="main_container">
-		<div id="left_admsection"><span id="admin_menu"></span>';
+		<div id="left_admsection">';
 
 	// What one are we rendering?
 	$context['cur_menu_id'] = isset($context['cur_menu_id']) ? $context['cur_menu_id'] + 1 : 1;

+ 3 - 2
Themes/default/Login.template.php

@@ -25,7 +25,7 @@ function template_login()
 					<img src="', $settings['images_url'], '/icons/login_sm.png" alt="" class="icon" /> ', $txt['login'], '
 				</h3>
 			</div>
-			<div class="roundframe"><br class="clear" />';
+			<div class="roundframe">';
 
 	// Did they make a mistake last time?
 	if (!empty($context['login_errors']))
@@ -186,7 +186,8 @@ function template_maintenance()
 				<dt>', $txt['always_logged_in'], ':</dt>
 				<dd><input type="checkbox" name="cookieneverexp" class="input_check" /></dd>
 			</dl>
-			<p class="centertext"><input type="submit" value="', $txt['login'], '" class="button_submit" /></p>
+			<input type="submit" value="', $txt['login'], '" class="button_submit" />
+			<br class="clear" />
 		</div>
 		<input type="hidden" name="hash_passwrd" value="" />
 		<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />

+ 3 - 8
Themes/default/ManageAttachments.template.php

@@ -52,8 +52,6 @@ function template_browse()
 	</div>';
 
 	template_show_list('file_list');
-	echo '
-	<br class="clear" />';
 
 }
 
@@ -76,7 +74,7 @@ function template_maintenance()
 				</dl>
 			</div>
 		</div>
-		<br class="clear" />
+
 		<div class="cat_bar">
 			<h3 class="catbg">', $txt['attachment_integrity_check'], '</h3>
 		</div>
@@ -90,7 +88,7 @@ function template_maintenance()
 				</form>
 			</div>
 		</div>
-		<br class="clear" />
+		
 		<div class="cat_bar">
 			<h3 class="catbg">', $txt['attachment_pruning'], '</h3>
 		</div>
@@ -122,12 +120,10 @@ function template_maintenance()
 					<input type="hidden" name="type" value="avatars" />
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 					<input type="hidden" name="sa" value="byAge" />
-					<br class="clear_right" />
 				</form>
 			</div>
 		</div>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_attachment_repair()
@@ -207,7 +203,6 @@ function template_attachment_paths()
 	if (!empty($modSettings['attachment_basedirectories']))
 	{
 		template_show_list('base_paths');
-		echo '<br />';
 	}
 
 	template_show_list('attach_paths');

+ 1 - 5
Themes/default/ManageBans.template.php

@@ -169,7 +169,6 @@ function template_ban_edit()
 						<input type="hidden" name="bg" value="', $context['ban']['id'], '" />
 						<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 						<input type="hidden" name="', $context['admin-bet_token_var'], '" value="', $context['admin-bet_token'], '" />
-						<br class="clear_right" />
 					</form>
 				</div>
 			</div>';
@@ -231,7 +230,6 @@ function template_ban_edit()
 						</div>
 					</div>
 				</div>
-				<br class="clear" />
 				<input type="hidden" name="bg" value="', $context['ban']['id'], '" />
 				<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 				<input type="hidden" name="', $context['admin-bet_token_var'], '" value="', $context['admin-bet_token'], '" />
@@ -241,7 +239,6 @@ function template_ban_edit()
 
 	echo '
 	</div>
-	<br class="clear" />
 	<script type="text/javascript" src="', $settings['default_theme_url'], '/scripts/suggest.js?alp21"></script>
 	<script type="text/javascript"><!-- // --><![CDATA[
 		var fUpdateStatus = function ()
@@ -330,7 +327,6 @@ function template_ban_edit_trigger()
 						</dl>
 					</fieldset>
 					<input type="submit" name="', $context['ban_trigger']['is_new'] ? 'add_new_trigger' : 'edit_trigger', '" value="', $context['ban_trigger']['is_new'] ? $txt['ban_add_trigger_submit'] : $txt['ban_edit_trigger_submit'], '" class="button_submit" />
-					<br class="clear_right" />
 				</div>
 			</div>
 			<input type="hidden" name="bi" value="' . $context['ban_trigger']['id'] . '" />
@@ -339,7 +335,7 @@ function template_ban_edit_trigger()
 			<input type="hidden" name="', $context['admin-bet_token_var'], '" value="', $context['admin-bet_token'], '" />
 		</form>
 	</div>
-	<br class="clear" />
+
 	<script type="text/javascript" src="', $settings['default_theme_url'], '/scripts/suggest.js?alp21"></script>
 	<script type="text/javascript"><!-- // --><![CDATA[
 		var oAddMemberSuggest = new smc_AutoSuggest({

+ 1 - 3
Themes/default/ManageCalendar.template.php

@@ -106,12 +106,10 @@ function template_edit_holiday()
 					<input type="hidden" name="holiday" value="', $context['holiday']['id'], '" />';
 	echo '
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-					<br class="clear_right" />
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 ?>

+ 38 - 42
Themes/default/ManageLanguages.template.php

@@ -33,8 +33,7 @@ function template_download_language()
 				', $context['install_complete'], '
 			</div>
 		</div>
-	</div>
-	<br class="clear" />';
+	</div>';
 		return;
 	}
 
@@ -193,8 +192,7 @@ function template_download_language()
 				<input type="submit" name="do_install" value="', $txt['add_language_smf_install'], '" class="button_submit" />
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 
 	// The javascript for expand and collapse of sections.
 	echo '
@@ -266,38 +264,38 @@ function template_modify_language_entries()
 				<div class="content">
 					<fieldset>
 						<legend>', $context['primary_settings']['name'], '</legend>
-					<dl class="settings">
-						<dt>
-							<label for="character_set">', $txt['languages_character_set'], ':</label>
-						</dt>
-						<dd>
-							<input type="text" name="character_set" id="character_set" size="20" value="', $context['primary_settings']['character_set'], '"', (empty($context['file_entries']) ? '' : ' disabled="disabled"'), ' class="input_text" />
-						</dd>
-						<dt>
-							<label for="locale>', $txt['languages_locale'], ':</label>
-						</dt>
-						<dd>
-							<input type="text" name="locale" id="locale" size="20" value="', $context['primary_settings']['locale'], '"', (empty($context['file_entries']) ? '' : ' disabled="disabled"'), ' class="input_text" />
-						</dd>
-						<dt>
-							<label for="dictionary">', $txt['languages_dictionary'], ':</label>
-						</dt>
-						<dd>
-							<input type="text" name="dictionary" id="dictionary" size="20" value="', $context['primary_settings']['dictionary'], '"', (empty($context['file_entries']) ? '' : ' disabled="disabled"'), ' class="input_text" />
-						</dd>
-						<dt>
-							<label for="spelling">', $txt['languages_spelling'], ':</label>
-						</dt>
-						<dd>
-							<input type="text" name="spelling" id="spelling" size="20" value="', $context['primary_settings']['spelling'], '"', (empty($context['file_entries']) ? '' : ' disabled="disabled"'), ' class="input_text" />
-						</dd>
-						<dt>
-							<label for="rtl">', $txt['languages_rtl'], ':</label>
-						</dt>
-						<dd>
-							<input type="checkbox" name="rtl" id="rtl" ', $context['primary_settings']['rtl'] ? ' checked="checked"' : '', ' class="input_check"', (empty($context['file_entries']) ? '' : ' disabled="disabled"'), ' />
-						</dd>
-					</dl>
+						<dl class="settings">
+							<dt>
+								<label for="character_set">', $txt['languages_character_set'], ':</label>
+							</dt>
+							<dd>
+								<input type="text" name="character_set" id="character_set" size="20" value="', $context['primary_settings']['character_set'], '"', (empty($context['file_entries']) ? '' : ' disabled="disabled"'), ' class="input_text" />
+							</dd>
+							<dt>
+								<label for="locale>', $txt['languages_locale'], ':</label>
+							</dt>
+							<dd>
+								<input type="text" name="locale" id="locale" size="20" value="', $context['primary_settings']['locale'], '"', (empty($context['file_entries']) ? '' : ' disabled="disabled"'), ' class="input_text" />
+							</dd>
+							<dt>
+								<label for="dictionary">', $txt['languages_dictionary'], ':</label>
+							</dt>
+							<dd>
+								<input type="text" name="dictionary" id="dictionary" size="20" value="', $context['primary_settings']['dictionary'], '"', (empty($context['file_entries']) ? '' : ' disabled="disabled"'), ' class="input_text" />
+							</dd>
+							<dt>
+								<label for="spelling">', $txt['languages_spelling'], ':</label>
+							</dt>
+							<dd>
+								<input type="text" name="spelling" id="spelling" size="20" value="', $context['primary_settings']['spelling'], '"', (empty($context['file_entries']) ? '' : ' disabled="disabled"'), ' class="input_text" />
+							</dd>
+							<dt>
+								<label for="rtl">', $txt['languages_rtl'], ':</label>
+							</dt>
+							<dd>
+								<input type="checkbox" name="rtl" id="rtl" ', $context['primary_settings']['rtl'] ? ' checked="checked"' : '', ' class="input_check"', (empty($context['file_entries']) ? '' : ' disabled="disabled"'), ' />
+							</dd>
+						</dl>
 					</fieldset>
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 					<input type="hidden" name="', $context['admin-mlang_token_var'], '" value="', $context['admin-mlang_token'], '" />
@@ -312,7 +310,6 @@ function template_modify_language_entries()
 	}
 
 	echo '
-					<br class="clear_right" />
 				</div>
 			</div>
 		</form>
@@ -342,8 +339,9 @@ function template_modify_language_entries()
 					</select>
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 					<input type="hidden" name="', $context['admin-mlang_token_var'], '" value="', $context['admin-mlang_token'], '" />
-					<input type="submit" value="', $txt['go'], '" class="button_submit" />
-			</div>';
+					<input type="submit" value="', $txt['go'], '" class="button_submit" style="float: none"/>
+			</div>
+			<br class="clear" />';
 
 	// Is it not writable?
 	// Show an error.
@@ -414,7 +412,6 @@ function template_modify_language_entries()
 
 		echo '
 				</div>
-				<br class="clear" />
 			</div>';
 	}
 	echo '
@@ -472,8 +469,7 @@ function template_add_language()
 
 	echo '
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 ?>

+ 6 - 9
Themes/default/ManageMaintenance.template.php

@@ -51,10 +51,7 @@ function template_maintain_database()
 
 	if ($db_type == 'sqlite')
 		echo '
-					<p>
-						<input type="submit" value="', $txt['maintain_backup_save'], '" id="submitDump" class="button_submit" />
-						<br class="clear_right" />
-					</p>';
+					<input type="submit" value="', $txt['maintain_backup_save'], '" id="submitDump" class="button_submit" />';
 	else
 	{
 		if ($context['safe_mode_enable'])
@@ -97,7 +94,7 @@ function template_maintain_database()
 				<form action="', $scripturl, '?action=admin;area=maintain;sa=database;activity=convertmsgbody" method="post" accept-charset="', $context['character_set'], '">
 					<p>', $txt['mediumtext_introduction'], '</p>',
 					$context['convert_to_suggest'] ? '<p class="infobox">' . $txt['convert_to_suggest_text'] . '</p>' : '', '
-					<input type="submit" name="evaluate_conversion" value="', $txt['maintain_run_now'], '" class="button_submit" /><br class="clear_right" />
+					<input type="submit" name="evaluate_conversion" value="', $txt['maintain_run_now'], '" class="button_submit" />
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 					<input type="hidden" name="', $context['admin-maint_token_var'], '" value="', $context['admin-maint_token'], '" />
 				</form>
@@ -159,10 +156,10 @@ function template_maintain_routine()
 
 	// If maintenance has finished tell the user.
 	if (!empty($context['maintenance_finished']))
-	echo '
-		<div class="maintenance_finished">
-			', sprintf($txt['maintain_done'], $context['maintenance_finished']), '
-		</div>';
+		echo '
+			<div class="maintenance_finished">
+				', sprintf($txt['maintain_done'], $context['maintenance_finished']), '
+			</div>';
 
 	echo '
 		<div class="cat_bar">

+ 2 - 6
Themes/default/ManageMembergroups.template.php

@@ -616,7 +616,6 @@ function template_group_members()
 						</dd>
 					</dl>
 					<input type="submit" name="add" value="', $txt['membergroups_members_add'], '" class="button_submit" />
-					<br class="clear_right" />
 				</div>
 			</div>';
 	}
@@ -625,8 +624,7 @@ function template_group_members()
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 			<input type="hidden" name="', $context['mod-mgm_token_var'], '" value="', $context['mod-mgm_token'], '" />
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 
 	if (!empty($context['group']['assignable']))
 		echo '
@@ -680,12 +678,10 @@ function template_group_request_reason()
 					<input type="submit" name="go" value="', $txt['mc_groupr_submit'], '" class="button_submit" />
 					<input type="hidden" name="req_action" value="got_reason" />
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-					<br class="clear_right" />
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 ?>

+ 1 - 1
Themes/default/ManageMembers.template.php

@@ -303,7 +303,7 @@ function template_admin_browse()
 							</select>
 						</dd>
 					</dl>
-					<input type="submit" value="', $txt['admin_browse_outstanding_go'], '" class="button_submit" /><br class="clear_right">
+					<input type="submit" value="', $txt['admin_browse_outstanding_go'], '" class="button_submit" />
 					<input type="hidden" name="type" value="', $context['browse_type'], '" />
 					<input type="hidden" name="sort" value="', $context['approve_list']['sort']['id'], '" />
 					<input type="hidden" name="start" value="', $context['approve_list']['start'], '" />

+ 4 - 5
Themes/default/ManageNews.template.php

@@ -42,7 +42,8 @@ function template_email_members()
 
 	echo '
 						</dd>
-					</dl><br class="clear" />
+					</dl>
+					<br class="clear" />
 				</div>
 			</div>
 			<br />
@@ -394,8 +395,7 @@ function template_email_members_compose()
 			}
 		// ]]></script>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_email_members_send()
@@ -434,12 +434,11 @@ function template_email_members_send()
 					<input type="hidden" name="', $key, '" value="', implode(($key == 'emails' ? ';' : ','), $values), '" />';
 
 	echo '
-				<br class="clear_right" />
 				</div>
 			</div>
 		</form>
 	</div>
-	<br class="clear" />
+
 	<script type="text/javascript"><!-- // --><![CDATA[
 		var countdown = 2;
 		doAutoSubmit();

+ 12 - 15
Themes/default/ManagePaid.template.php

@@ -188,12 +188,10 @@ function template_modify_subscription()
 					<input type="submit" name="save" value="', $txt['paid_settings_save'], '" class="button_submit" />
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 					<input type="hidden" name="', $context['admin-pms_token_var'], '" value="', $context['admin-pms_token'], '" />
-					<br class="clear_right" />
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 
 }
 
@@ -217,8 +215,7 @@ function template_delete_subscription()
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 
 }
 
@@ -377,8 +374,12 @@ function template_modify_user_subscription()
 			echo '
 					<li class="reset">
 						', $payment['desc'], '
-						<span class="floatleft"><a href="', $scripturl, '?action=admin;area=paidsubscribe;sa=modifyuser;lid=', $context['log_id'], ';pending=', $id, ';accept">', $txt['pending_payments_accept'], '</a></span>
-						<span class="floatright"><a href="', $scripturl, '?action=admin;area=paidsubscribe;sa=modifyuser;lid=', $context['log_id'], ';pending=', $id, ';remove">', $txt['pending_payments_remove'], '</a></span>
+						<span class="floatleft">
+							<a href="', $scripturl, '?action=admin;area=paidsubscribe;sa=modifyuser;lid=', $context['log_id'], ';pending=', $id, ';accept">', $txt['pending_payments_accept'], '</a>
+						</span>
+						<span class="floatright">
+							<a href="', $scripturl, '?action=admin;area=paidsubscribe;sa=modifyuser;lid=', $context['log_id'], ';pending=', $id, ';remove">', $txt['pending_payments_remove'], '</a>
+						</span>
 					</li>';
 		}
 
@@ -389,8 +390,7 @@ function template_modify_user_subscription()
 	}
 
 	echo '
-		</div>
-	<br class="clear" />';
+		</div>';
 }
 
 // Template for a user to edit/pick their subscriptions.
@@ -466,8 +466,7 @@ function template_user_subscription()
 
 				echo '
 					<hr class="hrcolor" />
-					<input type="submit" name="sub_id[', $subscription['id'], ']" value="', $txt['paid_order'], '" class="button_submit" />
-					<br class="clear_right" />';
+					<input type="submit" name="sub_id[', $subscription['id'], ']" value="', $txt['paid_order'], '" class="button_submit" />';
 			}
 			else
 				echo '
@@ -529,8 +528,7 @@ function template_user_subscription()
 	echo '
 			</tbody>
 		</table>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // The "choose payment" dialog.
@@ -616,8 +614,7 @@ function template_paid_done()
 				<a href="', $scripturl, '?action=profile;u=', $context['member']['id'], ';area=subscriptions">', $txt['paid_sub_return'], '</a>
 			</div>
 		</div>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 ?>

+ 9 - 18
Themes/default/ManagePermissions.template.php

@@ -183,7 +183,6 @@ function template_permission_index()
 						</dl>
 					</fieldset>
 					<input type="submit" value="', $txt['permissions_set_permissions'], '" onclick="return checkSubmit();" class="button_submit" />
-					<br class="clear_right" />
 				</div>
 			</div>';
 
@@ -257,8 +256,7 @@ function template_permission_index()
 
 	echo '
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_by_board()
@@ -282,9 +280,8 @@ function template_by_board()
 
 	if (!$context['edit_all'])
 		echo '
-			<div class="content">
+			<div class="content flow_auto">
 			<a class="button_link" href="', $scripturl, '?action=admin;area=permissions;sa=board;edit;', $context['session_var'], '=', $context['session_id'], '">', $txt['permissions_board_all'], '</a>
-			<br class="clear_right" />
 			</div>';
 
 	foreach ($context['categories'] as $category)
@@ -355,8 +352,7 @@ function template_by_board()
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 			<input type="hidden" name="', $context['admin-mpb_token_var'], '" value="', $context['admin-mpb_token'], '" />
 		</div>
-	</form>
-	<br class="clear" />';
+	</form>';
 }
 
 // Edit permission profiles (predefined).
@@ -409,7 +405,7 @@ function template_edit_profiles()
 	echo '
 				</tbody>
 			</table>
-			<div class="righttext padding">
+			<div class="flow_auto righttext padding">
 				<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 				<input type="hidden" name="', $context['admin-mpp_token_var'], '" value="', $context['admin-mpp_token'], '" />';
 
@@ -419,7 +415,6 @@ function template_edit_profiles()
 
 	echo '
 				<input type="submit" name="delete" value="', $txt['quickmod_delete_selected'], '" class="button_submit" />
-				<br class="clear" />
 			</div>
 		</form>
 		<br />
@@ -454,12 +449,10 @@ function template_edit_profiles()
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 					<input type="hidden" name="', $context['admin-mpp_token_var'], '" value="', $context['admin-mpp_token'], '" />
 					<input type="submit" name="create" value="', $txt['permissions_profile_new_create'], '" class="button_submit" />
-					<br class="clear_right" />
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_modify_group()
@@ -551,7 +544,7 @@ function template_modify_group()
 
 	if ($context['profile']['can_modify'])
 		echo '
-			<div class="righttext padding">
+			<div class="padding">
 				<input type="submit" value="', $txt['permissions_commit'], '" class="button_submit" />
 			</div>';
 
@@ -559,8 +552,7 @@ function template_modify_group()
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 			<input type="hidden" name="', $context['admin-mp_token_var'], '" value="', $context['admin-mp_token'], '" />
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 
 }
 
@@ -1090,7 +1082,7 @@ function template_postmod_permissions()
 
 	echo '
 					</select>
-					<input type="submit" value="', $txt['go'], '" class="button_submit" />
+					<input type="submit" value="', $txt['go'], '" class="button_submit" style="margin-top: 5px;" />
 			</div>
 			<table width="100%" class="table_grid">
 				<thead>
@@ -1170,8 +1162,7 @@ function template_postmod_permissions()
 			<img src="', $settings['default_images_url'], '/admin/post_moderation_moderate.png" alt="', $txt['permissions_post_moderation_moderate'], '" /> - ', $txt['permissions_post_moderation_moderate'], '<br />
 			<img src="', $settings['default_images_url'], '/admin/post_moderation_deny.png" alt="', $txt['permissions_post_moderation_disallow'], '" /> - ', $txt['permissions_post_moderation_disallow'], '
 		</p>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 ?>

+ 1 - 2
Themes/default/ManageScheduledTasks.template.php

@@ -87,8 +87,7 @@ function template_edit_scheduled_tasks()
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 ?>

+ 8 - 19
Themes/default/ManageSearch.template.php

@@ -83,12 +83,10 @@ function template_modify_weights()
 					<input type="submit" name="save" value="', $txt['search_weights_save'], '" class="button_submit" />
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 					<input type="hidden" name="', $context['admin-msw_token_var'], '" value="', $context['admin-msw_token'], '" />
-					<br class="clear_right" />
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_select_search_method()
@@ -125,7 +123,7 @@ function template_select_search_method()
 						</dd>';
 	echo '
 					</dl>
-					', $context['double_index'] ? '<div class="information">
+					', $context['double_index'] ? '<div class="noticebox">
 					' . $txt['search_double_index'] . '</div>' : '', '
 					<fieldset class="search_settings floatleft">
 						<legend>', $txt['search_index'], '</legend>
@@ -211,12 +209,10 @@ function template_select_search_method()
 					<input type="submit" name="save" value="', $txt['search_method_save'], '" class="button_submit" />
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 					<input type="hidden" name="', $context['admin-msmpost_token_var'], '" value="', $context['admin-msmpost_token'], '" />
-					<br class="clear_right" />
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_create_index()
@@ -246,7 +242,6 @@ function template_create_index()
 					<hr class="hrcolor" />
 					<input type="submit" name="save" value="', $txt['search_create_index_start'], '" class="button_submit" />
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-					<br class="clear_right" />
 				</div>
 			</div>
 	</form>
@@ -273,7 +268,6 @@ function template_create_index_progress()
 					</div>
 					<hr class="hrcolor" />
 					<input type="submit" name="b" value="', $txt['search_create_index_continue'], '" class="button_submit" />
-					<br class="clear_right" />
 				</div>
 			</div>
 			<input type="hidden" name="step" value="', $context['step'], '" />
@@ -282,7 +276,6 @@ function template_create_index_progress()
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 		</form>
 	</div>
-	<br class="clear" />
 	<script type="text/javascript"><!-- // --><![CDATA[
 		var countdown = 10;
 		doAutoSubmit();
@@ -319,8 +312,7 @@ function template_create_index_done()
 				</p>
 			</div>
 		</div>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // Add or edit a search engine spider.
@@ -365,12 +357,10 @@ function template_spider_edit()
 					<input type="submit" name="save" value="', $context['page_title'], '" class="button_submit" />
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 					<input type="hidden" name="', $context['admin-ses_token_var'], '" value="', $context['admin-ses_token'], '" />
-					<br class="clear_right" />
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // Show... spider... logs...
@@ -385,6 +375,7 @@ function template_show_spider_logs()
 	template_show_list('spider_logs');
 
 	echo '
+		<br class="clear" />
 		<form id="admin_form_wrapper" action="', $scripturl, '?action=admin;area=sengines;sa=logs" method="post" accept-charset="', $context['character_set'], '">
 			<div class="cat_bar">
 				<h3 class="catbg">', $txt['spider_logs_delete'], '</h3>
@@ -402,8 +393,7 @@ function template_show_spider_logs()
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // Show... spider... stats...
@@ -436,8 +426,7 @@ function template_show_spider_stats()
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 ?>

+ 9 - 17
Themes/default/ManageSmileys.template.php

@@ -31,7 +31,7 @@ function template_editsets()
 			</div>
 		</div>
 	</div>
-	<br class="clear" />
+	
 	<script type="text/javascript"><!-- // --><![CDATA[
 		window.smfForum_scripturl = "', $scripturl, '";
 		window.smfForum_sessionid = "', $context['session_id'], '";
@@ -144,15 +144,13 @@ function template_modifyset()
 					</dl>
 					<hr class="hrcolor" />
 					<input type="submit" name="smiley_save" value="', $txt['smiley_sets_save'], '" class="button_submit" />
-					<br class="clear_right" />
 				</div>
 			</div>
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 			<input type="hidden" name="', $context['admin-mss_token_var'], '" value="', $context['admin-mss_token'], '" />
 			<input type="hidden" name="set" value="', $context['current_set']['id'], '" />
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // Editing an individual smiley
@@ -233,14 +231,13 @@ function template_modifysmiley()
 					<hr class="hrcolor" />
 					<input type="submit" name="smiley_save" value="', $txt['smileys_save'], '" class="button_submit" />
 					<input type="submit" name="deletesmiley" value="', $txt['smileys_delete'], '" onclick="return confirm(\'', $txt['smileys_delete_confirm'], '\');" class="button_submit" />
-					<br class="clear_right" />
 				</div>
 			</div>
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 			<input type="hidden" name="smiley" value="', $context['current_smiley']['id'], '" />
 		</form>
 	</div>
-	<br class="clear" />
+	
 	<script type="text/javascript"><!-- // --><![CDATA[
 		function updatePreview()
 		{
@@ -342,7 +339,7 @@ function template_addsmiley()
 					</dl>
 				</div>
 			</div>
-			<br class="clear" />
+			
 			<div class="cat_bar">
 				<h3 class="catbg">', $txt['smiley_new'], '</h3>
 			</div>
@@ -380,13 +377,11 @@ function template_addsmiley()
 					</dl>
 					<hr class="hrcolor" />
 					<input type="submit" name="smiley_save" value="', $txt['smileys_save'], '" class="button_submit" />
-					<br class="clear_right" />
 				</div>
 			</div>
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // Ordering smileys.
@@ -434,12 +429,11 @@ function template_setorder()
 				</div>
 			</div>
 		<input type="hidden" name="reorder" value="1" />
-	</form>
-	<br />';
+	</form>';
 	}
+	
 	echo '
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // Editing Message Icons
@@ -533,12 +527,10 @@ function template_editicon()
 					<hr class="hrcolor" />
 					<input type="submit" name="icons_save" value="', $txt['smileys_save'], '" class="button_submit" />
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-					<br class="clear_right" />
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 ?>

+ 3 - 2
Themes/default/Memberlist.template.php

@@ -194,8 +194,9 @@ function template_search()
 	echo '
 					</dl>
 					<hr class="hrcolor" />
-					<input type="submit" name="submit" value="' . $txt['search'] . '" class="button_submit" />
-					<br class="clear_right" />
+					<div class="flow_auto">
+						<input type="submit" name="submit" value="' . $txt['search'] . '" class="button_submit" />
+					</div>
 				</div>
 			</div>
 		</div>

+ 5 - 9
Themes/default/MessageIndex.template.php

@@ -252,7 +252,7 @@ function template_main()
 						</div>
 					</td>
 					<td class="', $alternate_class, ' subject">
-						<div ', (!empty($topic['quick_mod']['modify']) ? 'id="topic_' . $topic['first_post']['id'] . '" onmouseout="mouse_on_div = 0;" onmouseover="mouse_on_div = 1;" ondblclick="modify_topic(\'' . $topic['id'] . '\', \'' . $topic['first_post']['id'] . '\');"' : ''), '>';
+						<div ', (!empty($topic['quick_mod']['modify']) ? 'id="topic_' . $topic['first_post']['id'] . '"  ondblclick="oQuickModifyTopic.modify_topic(\'' . $topic['id'] . '\', \'' . $topic['first_post']['id'] . '\');"' : ''), '>';
 
 			// [WIP] Methinks the orange icons look better if they aren't all over the page.
 			// Is this topic new? (assuming they are logged in!)
@@ -425,14 +425,10 @@ function template_main()
 	echo '
 <script type="text/javascript" src="', $settings['default_theme_url'], '/scripts/topic.js"></script>
 <script type="text/javascript"><!-- // --><![CDATA[
-
-	// Hide certain bits during topic edit.
-	hide_prefixes.push("lockicon", "stickyicon", "pages", "newicon");
-
-	// Use it to detect when we\'ve stopped editing.
-	document.onclick = modify_topic_click;
-
-	var mouse_on_div;
+	var oQuickModifyTopic = new QuickModifyTopic({
+		aHidePrefixes: Array("lockicon", "stickyicon", "pages", "newicon"),
+		bMouseOnDiv: false,
+	});
 // ]]></script>';
 }
 

+ 9 - 18
Themes/default/ModerationCenter.template.php

@@ -69,7 +69,6 @@ function template_latest_news()
 	echo '
 		<script type="text/javascript" src="', $scripturl, '?action=viewsmfile;filename=current-version.js"></script>
 		<script type="text/javascript" src="', $scripturl, '?action=viewsmfile;filename=latest-news.js"></script>
-		<script type="text/javascript" src="', $settings['default_theme_url'], '/scripts/admin.js?alp21"></script>
 		<script type="text/javascript"><!-- // --><![CDATA[
 			var oAdminIndex = new smf_AdminIndex({
 				sSelf: \'oAdminCenter\',
@@ -227,10 +226,7 @@ function template_notes()
 					<div class="floatleft post_note">
 						<input type="text" name="new_note" value="', $txt['mc_click_add_note'], '" style="width: 95%;" onclick="if (this.value == \'', $txt['mc_click_add_note'], '\') this.value = \'\';" class="input_text" />
 					</div>
-					<div class="floatright">
-						<input type="submit" name="makenote" value="', $txt['mc_add_note'], '" class="button_submit" />
-					</div>
-					<br class="clear" />
+					<input type="submit" name="makenote" value="', $txt['mc_add_note'], '" class="button_submit" />
 				</div>
 			</div>
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
@@ -369,7 +365,6 @@ function template_unapproved_posts()
 
 			echo '
 					</span>
-					<br class="clear" />
 				</div>
 			</div>
 		</div>';
@@ -400,8 +395,7 @@ function template_unapproved_posts()
 		</div>
 		<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 	</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // List all attachments awaiting approval.
@@ -422,8 +416,7 @@ function template_unapproved_attachments()
 	template_show_list('mc_unapproved_attach');
 
 	echo '
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_viewmodreport()
@@ -485,7 +478,9 @@ function template_viewmodreport()
 
 	if (empty($context['report']['mod_comments']))
 		echo '
-					<p class="centertext">', $txt['mc_modreport_no_mod_comment'], '</p>';
+				<div class="information">
+					<p class="centertext">', $txt['mc_modreport_no_mod_comment'], '</p>
+				</div>';
 
 	foreach ($context['report']['mod_comments'] as $comment)
 		echo
@@ -507,8 +502,7 @@ function template_viewmodreport()
 	echo '
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // Callback function for showing a watched users post in the table.
@@ -614,12 +608,10 @@ function template_moderation_settings()
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 					<input type="hidden" name="', $context['mod-set_token_var'], '" value="', $context['mod-set_token'], '" />
 					<input type="submit" name="save" value="', $txt['save'], '" class="button_submit" />
-					<br class="clear_right" />
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // Show a notice sent to a user.
@@ -725,14 +717,13 @@ function template_warn_template()
 					<hr class="hrcolor" />
 					<input type="submit" name="preview" id="preview_button" value="', $txt['preview'], '" class="button_submit" />
 					<input type="submit" name="save" value="', $context['page_title'], '" class="button_submit" />
-					<br class="clear_right" />
 				</div>
 			</div>
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 			<input type="hidden" name="', $context['mod-wt_token_var'], '" value="', $context['mod-wt_token'], '" />
 		</form>
 	</div>
-	<br class="clear" />
+
 	<script type="text/javascript"><!-- // --><![CDATA[
 		$(document).ready(function() {
 			$("#preview_button").click(function() {

+ 0 - 1
Themes/default/MoveTopic.template.php

@@ -91,7 +91,6 @@ function template_main()
 							</dl>
 						</fieldset>
 						<input type="submit" value="', $txt['move_topic'], '" onclick="return submitThisOnce(this);" accesskey="s" class="button_submit" />
-						<br class="clear_right" />
 					</div>
 				</div>
 			</div>';

+ 19 - 33
Themes/default/Packages.template.php

@@ -41,8 +41,8 @@ function template_view_package()
 	{
 		echo '
 		<div class="errorbox">
-			', $txt['package_will_fail_title'], '<br />
-			', $txt['package_will_fail_warning'],
+			', sprintf($txt['package_will_fail_title'], $txt['package_' . ($context['uninstalling'] ? 'uninstall' : 'install')]), '<br />
+			', sprintf($txt['package_will_fail_warning'], $txt['package_' . ($context['uninstalling'] ? 'uninstall' : 'install')]),
 			!empty($context['failure_details']) ? '<br /><br /><strong>' . $context['failure_details'] . '</strong>' : '', '
 		</div>';
 	}
@@ -142,7 +142,7 @@ function template_view_package()
 					<th scope="col" width="30"></th>
 					<th scope="col" class="lefttext">', $txt['package_install_type'], '</th>
 					<th scope="col" class="lefttext" width="50%">', $txt['package_install_action'], '</th>
-					<th class="last_th lefttext" scope="col" class="lefttext" width="20%">', $txt['package_install_desc'], '</th>
+					<th class="last_th lefttext" scope="col" width="20%">', $txt['package_install_desc'], '</th>
 				</tr>
 			</thead>
 			<tbody>';
@@ -331,8 +331,7 @@ function template_view_package()
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />', (isset($context['form_sequence_number']) && !$context['ftp_needed']) ? '
 			<input type="hidden" name="seqnum" value="' . $context['form_sequence_number'] . '" />' : '', '
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 
 	// Toggle options.
 	echo '
@@ -468,8 +467,7 @@ function template_extract_package()
 	}
 
 	echo '
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_list()
@@ -498,8 +496,7 @@ function template_list()
 				<a href="', $scripturl, '?action=admin;area=packages">[ ', $txt['back'], ' ]</a>
 			</div>
 		</div>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_examine()
@@ -520,8 +517,7 @@ function template_examine()
 				<a href="', $scripturl, '?action=admin;area=packages;sa=list;package=', $context['package'], '">[ ', $txt['list_files'], ' ]</a>
 			</div>
 		</div>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_browse()
@@ -589,7 +585,6 @@ function template_browse()
 
 	// the advanced (emulation) box, collapsed by default
 	echo '
-		<br class="clear" />
 		<form action="', $scripturl, '?action=admin;area=packages;sa=', $context['sub_action'], '" method="get">
 			<div id="advanced_box" >
 				<div class="cat_bar">
@@ -627,7 +622,7 @@ function template_browse()
 
 	echo '
 	</div>
-	<br class="clear" />
+	
 	<script type="text/javascript"><!-- // --><![CDATA[
 		var oAdvancedPanelToggle = new smc_Toggle({
 			bToggleEnabled: true,
@@ -818,12 +813,10 @@ function template_servers()
 					<hr class="hrcolor" />
 					<input type="submit" value="' . $txt['package_upload'] . '" class="button_submit" />
 					<input type="hidden" name="' . $context['session_var'] . '" value="' . $context['session_id'] . '" />
-					<br class="clear_right" />
 				</form>
 			</div>
 		</div>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_package_confirm()
@@ -841,8 +834,7 @@ function template_package_confirm()
 				<a href="', $context['proceed_href'], '">[ ', $txt['package_confirm_proceed'], ' ]</a> <a href="JavaScript:history.go(-1);">[ ', $txt['package_confirm_go_back'], ' ]</a>
 			</div>
 		</div>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_package_list()
@@ -872,7 +864,7 @@ function template_package_list()
 		{
 			echo '
 					<li>
-						<strong><img id="ps_img_', $i, '" src="', $settings['images_url'], '/upshrink.png" alt="*" style="display: none;" /> ', $packageSection['title'], '</strong>';
+						<strong><img id="ps_img_', $i, '" src="', $settings['images_url'], '/collapse.png" alt="*" style="display: none;" /> ', $packageSection['title'], '</strong>';
 
 			if (!empty($packageSection['text']))
 				echo '
@@ -912,7 +904,7 @@ function template_package_list()
 				{
 					// 1. Some mod [ Download ].
 					echo '
-							<strong><img id="ps_img_', $i, '_pkg_', $id, '" src="', $settings['images_url'], '/upshrink.png" alt="*" style="display: none;" /> ', $package['can_install'] ? '<strong>' . $package['name'] . '</strong> <a href="' . $package['download']['href'] . '">[ ' . $txt['download'] . ' ]</a>': $package['name'];
+							<strong><img id="ps_img_', $i, '_pkg_', $id, '" src="', $settings['images_url'], '/collapse.png" alt="*" style="display: none;" /> ', $package['can_install'] ? '<strong>' . $package['name'] . '</strong> <a href="' . $package['download']['href'] . '">[ ' . $txt['download'] . ' ]</a>': $package['name'];
 
 					// Mark as installed and current?
 					if ($package['is_installed'] && !$package['is_newer'])
@@ -968,7 +960,6 @@ function template_package_list()
 			<img src="', $settings['images_url'], '/icons/package_old.png" alt="" class="centericon" style="margin-left: 2ex;" /> ', $txt['package_installed_old'], '
 		</div>
 	</div>
-	<br class="clear" />
 
 		';
 		// Now go through and turn off all the sections.
@@ -989,9 +980,9 @@ function template_package_list()
 					aSwapImages: [
 						{
 							sId: \'ps_img_', $section, '\',
-							srcExpanded: smf_images_url + \'/upshrink.png\',
+							srcExpanded: smf_images_url + \'/collapse.png\',
 							altExpanded: \'*\',
-							srcCollapsed: smf_images_url + \'/upshrink2.png\',
+							srcCollapsed: smf_images_url + \'/expand.png\',
 							altCollapsed: \'*\'
 						}
 					]
@@ -1010,9 +1001,9 @@ function template_package_list()
 					aSwapImages: [
 						{
 							sId: \'ps_img_', $section, '_pkg_', $id, '\',
-							srcExpanded: smf_images_url + \'/upshrink.png\',
+							srcExpanded: smf_images_url + \'/collapse.png\',
 							altExpanded: \'*\',
-							srcCollapsed: smf_images_url + \'/upshrink2.png\',
+							srcCollapsed: smf_images_url + \'/expand.png\',
 							altCollapsed: \'*\'
 						}
 					]
@@ -1046,8 +1037,7 @@ function template_downloaded()
 				<p><a href="', $scripturl, '?action=admin;area=packages;get', (isset($context['package_server']) ? ';sa=browse;server=' . $context['package_server'] : ''), '">[ ', $txt['back'], ' ]</a></p>
 			</div>
 		</div>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_install_options()
@@ -1101,12 +1091,10 @@ function template_install_options()
 					<hr class="hrcolor" />
 					<input type="submit" name="save" value="', $txt['save'], '" class="button_submit" />
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-					<br class="clear_right" />
 				</form>
 			</div>
 		</div>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_control_chmod()
@@ -1616,7 +1604,6 @@ function template_file_permissions()
 				<hr class="hrcolor" />
 				<input type="hidden" name="action_changes" value="1" />
 				<input type="submit" value="', $txt['package_file_perms_go'], '" name="go" class="button_submit" />
-				<br class="clear_right" />
 			</div>
 		</div>';
 
@@ -1799,8 +1786,7 @@ function template_action_permissions()
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 
 	// Just the countdown stuff
 	echo '

+ 7 - 11
Themes/default/PersonalMessage.template.php

@@ -440,7 +440,7 @@ function template_folder()
 			if ($context['folder'] != 'sent' && !empty($context['currently_using_labels']) && $context['display_mode'] != 2)
 			{
 				echo '
-				<div class="labels righttext">';
+				<div class="labels righttext flow_auto">';
 				// Add the label drop down box.
 				if (!empty($context['currently_using_labels']))
 				{
@@ -480,7 +480,6 @@ function template_folder()
 
 			echo '
 			</div>
-			<br class="clear" />
 		</div>
 		<div class="moderatorbar">
 		</div>
@@ -632,7 +631,7 @@ function template_subject_list()
 		}
 
 		echo '
-				<input type="submit" name="del_selected" value="', $txt['quickmod_delete_selected'], '" onclick="if (!confirm(\'', $txt['delete_selected_confirm'], '\')) return false;" class="button_submit" />';
+				<input type="submit" name="del_selected" value="', $txt['quickmod_delete_selected'], '" onclick="if (!confirm(\'', $txt['delete_selected_confirm'], '\')) return false;" class="button_submit" style="float: none" />';
 	}
 
 	echo '
@@ -714,7 +713,7 @@ function template_search()
 				</dl>';
 		if (!$context['currently_using_labels'])
 			echo '
-				<input type="submit" name="pm_search" value="', $txt['pm_search_go'], '" class="button_submit floatright" />';
+				<input type="submit" name="pm_search" value="', $txt['pm_search_go'], '" class="button_submit" />';
 			echo '
 				<br class="clear_right" />
 			</div>
@@ -1333,10 +1332,7 @@ function template_prune()
 		<div class="windowbg">
 			<div class="content">
 				<p>', $txt['pm_prune_desc1'], ' <input type="text" name="age" size="3" value="14" class="input_text" /> ', $txt['pm_prune_desc2'], '</p>
-				<div class="righttext">
-					<input type="submit" value="', $txt['delete'], '" class="button_submit" />
-				</div>
-				<br class="clear" />
+				<input type="submit" value="', $txt['delete'], '" class="button_submit" />
 			</div>
 		</div>
 		<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
@@ -1403,7 +1399,7 @@ function template_labels()
 
 	if (!count($context['labels']) < 2)
 		echo '
-		<div class="padding righttext">
+		<div class="padding">
 			<input type="submit" name="save" value="', $txt['save'], '" class="button_submit" />
 			<input type="submit" name="delete" value="', $txt['quickmod_delete_selected'], '" onclick="return confirm(\'', $txt['pm_labels_delete'], '\');" class="button_submit" />
 		</div>';
@@ -1428,7 +1424,6 @@ function template_labels()
 				</dl>
 				<hr class="hrcolor" />
 				<input type="submit" name="add" value="', $txt['pm_label_add_new'], '" class="button_submit" />
-				<br class="clear_right" />
 			</div>
 		</div>
 		<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
@@ -1840,7 +1835,8 @@ function template_add_rule()
 					<a href="#" onclick="addActionOption(); return false;" id="addonjs2" style="display: none;">(', $txt['pm_rule_add_action'], ')</a>
 				</fieldset>
 			</div>
-		</div><br class="clear" />
+		</div>
+		
 		<div class="cat_bar">
 			<h3 class="catbg">', $txt['pm_rule_description'], '</h3>
 		</div>

+ 1 - 2
Themes/default/Poll.template.php

@@ -141,10 +141,9 @@ function template_main()
 						<input type="checkbox" name="resetVoteCount" value="on" class="input_check" /> ' . $txt['reset_votes_check'] . '
 					</fieldset>';
 	echo '
-					<div class="righttext padding">
+					<div class="padding flow_auto">
 						<input type="submit" name="post" value="', $txt['save'], '" onclick="return submitThisOnce(this);" accesskey="s" class="button_submit" />
 					</div>
-					<br class="clear" />
 				</div>
 			</div>
 			<input type="hidden" name="seqnum" value="', $context['form_sequence_number'], '" />

+ 4 - 3
Themes/default/Profile.template.php

@@ -594,6 +594,7 @@ function template_editBuddies()
 					</dt>
 					<dd>
 						<input type="text" name="new_buddy" id="new_buddy" size="30" class="input_text" />
+						<input type="submit" value="', $txt['buddy_add_button'], '" class="button_submit floatnone" />
 					</dd>
 				</dl>';
 
@@ -603,7 +604,7 @@ function template_editBuddies()
 
 	echo '
 				<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-				<input type="submit" value="', $txt['buddy_add_button'], '" class="button_submit" />
+				
 			</div>
 		</div>
 	</form>
@@ -2950,14 +2951,14 @@ function template_authentication_method()
 								</dt>
 								<dd>
 									<input type="password" name="passwrd1" id="smf_autov_pwmain" size="30" tabindex="', $context['tabindex']++, '" class="input_password" />
-									<span id="smf_autov_pwmain_div" style="display: none;"><img id="smf_autov_pwmain_img" src="', $settings['images_url'], '/icons/field_invalid.png" alt="*" /></span>
+									<span id="smf_autov_pwmain_div" style="display: none;"><img id="smf_autov_pwmain_img" class="centericon" src="', $settings['images_url'], '/icons/field_invalid.png" alt="*" /></span>
 								</dd>
 								<dt>
 									<em>', $txt['verify_pass'], ':</em>
 								</dt>
 								<dd>
 									<input type="password" name="passwrd2" id="smf_autov_pwverify" size="30" tabindex="', $context['tabindex']++, '" class="input_password" />
-									<span id="smf_autov_pwverify_div" style="display: none;"><img id="smf_autov_pwverify_img" src="', $settings['images_url'], '/icons/field_valid.png" alt="*" /></span>
+									<span id="smf_autov_pwverify_div" style="display: none;"><img id="smf_autov_pwverify_img" class="centericon"  src="', $settings['images_url'], '/icons/field_valid.png" alt="*" /></span>
 								</dd>
 							</dl>
 						</dd>

+ 1 - 1
Themes/default/Recent.template.php

@@ -167,7 +167,7 @@ function template_unread()
 			// [WIP] MEthinks the orange icons look better if they aren't all over the page.
 			echo '
 									<a href="', $topic['new_href'], '" id="newicon', $topic['first_post']['id'], '"><span class="new_posts">' . $txt['new'] . '</span></a>
-									', $topic['is_sticky'] ? '<strong>' : '', '<span title="', $topic[(empty($settings['message_index_preview_first']) ? 'last_post' : 'first_post')]['preview'], '"><span id="msg_' . $topic['first_post']['id'] . '">', $topic['first_post']['link'], '</span>', $topic['is_sticky'] ? '</strong>' : '', '
+									', $topic['is_sticky'] ? '<strong>' : '', '<span class="preview" title="', $topic[(empty($settings['message_index_preview_first']) ? 'last_post' : 'first_post')]['preview'], '"><span id="msg_' . $topic['first_post']['id'] . '">', $topic['first_post']['link'], '</span></span>', $topic['is_sticky'] ? '</strong>' : '', '
 									<p>
 										', $topic['first_post']['started_by'], '
 										<small id="pages', $topic['first_post']['id'], '">', $topic['pages'], '</small>

+ 27 - 22
Themes/default/Register.template.php

@@ -329,7 +329,7 @@ function template_registration_form()
 	}
 
 	echo '
-			<div id="confirm_buttons">';
+			<div id="confirm_buttons flow_auto">';
 
 	// Age restriction in effect?
 	if (!$context['require_agreement'] && $context['show_coppa'])
@@ -345,7 +345,7 @@ function template_registration_form()
 			<input type="hidden" name="', $context['register_token_var'], '" value="', $context['register_token'], '" />
 			<input type="hidden" name="step" value="2" />
 		</form>
-		<br class="clear" />
+		
 		<script type="text/javascript"><!-- // --><![CDATA[
 			var regTextStrings = {
 				"username_valid": "', $txt['registration_username_available'], '",
@@ -578,12 +578,14 @@ function template_admin_register()
 					</dd>
 				</dl>
 				<hr class="hrcolor" />
-				<input type="submit" name="regSubmit" value="', $txt['register'], '" tabindex="', $context['tabindex']++, '" class="button_submit" />
-				<input type="hidden" name="sa" value="register" />
-				<br class="clear_right" />
+				<div class="flow_auto">
+					<input type="submit" name="regSubmit" value="', $txt['register'], '" tabindex="', $context['tabindex']++, '" class="button_submit" />
+					<input type="hidden" name="sa" value="register" />
+					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
+					<input type="hidden" name="', $context['admin-regc_token_var'], '" value="', $context['admin-regc_token'], '" />
+				</div>
 			</div>
-			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-			<input type="hidden" name="', $context['admin-regc_token_var'], '" value="', $context['admin-regc_token'], '" />
+			
 		</form>
 	</div>
 	<br class="clear" />';
@@ -645,16 +647,16 @@ function template_edit_agreement()
 						<label for="requireAgreement"><input type="checkbox" name="requireAgreement" id="requireAgreement"', $context['require_agreement'] ? ' checked="checked"' : '', ' tabindex="', $context['tabindex']++, '" value="1" class="input_check" /> ', $txt['admin_agreement'], '.</label>
 					</p>
 					<hr class="hrcolor" />
-					<input type="submit" value="', $txt['save'], '" tabindex="', $context['tabindex']++, '" class="button_submit" />
-					<input type="hidden" name="agree_lang" value="', $context['current_agreement'], '" />
-					<input type="hidden" name="sa" value="agreement" />
-					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-					<input type="hidden" name="', $context['admin-rega_token_var'], '" value="', $context['admin-rega_token'], '" />
-					<br class="clear_right" />
+					<div class="flow_auto" >
+						<input type="submit" value="', $txt['save'], '" tabindex="', $context['tabindex']++, '" class="button_submit" />
+						<input type="hidden" name="agree_lang" value="', $context['current_agreement'], '" />
+						<input type="hidden" name="sa" value="agreement" />
+						<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
+						<input type="hidden" name="', $context['admin-rega_token_var'], '" value="', $context['admin-rega_token'], '" />
+					</div>
 				</form>
 			</div>
-		</div>
-		<br class="clear" />';
+		</div>';
 }
 
 function template_edit_reserved_words()
@@ -698,14 +700,17 @@ function template_edit_reserved_words()
 					</dd>
 				</dl>
 				<hr class="hrcolor" />
-				<input type="submit" value="', $txt['save'], '" name="save_reserved_names" tabindex="', $context['tabindex']++, '" style="margin: 1ex;" class="button_submit" />
-				<br class="clear_right" />
+				<div class="flow_auto" >
+					<input type="submit" value="', $txt['save'], '" name="save_reserved_names" tabindex="', $context['tabindex']++, '" style="margin: 1ex;" class="button_submit" />
+					<input type="hidden" name="sa" value="reservednames" />
+					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
+					<input type="hidden" name="', $context['admin-regr_token_var'], '" value="', $context['admin-regr_token'], '" />
+				</div>
 			</div>
-			<input type="hidden" name="sa" value="reservednames" />
-			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-			<input type="hidden" name="', $context['admin-regr_token_var'], '" value="', $context['admin-regr_token'], '" />
-		</form>
-		<br class="clear" />';
+		</form>';
 }
 
+
+
+
 ?>

+ 12 - 11
Themes/default/Reminder.template.php

@@ -57,14 +57,14 @@ function template_reminder_pick()
 					<input type="radio" name="reminder_type" id="reminder_type_secret" value="secret" class="input_radio" />
 					<label for="reminder_type_secret">', $txt['authentication_' . $context['account_type'] . '_secret'], '</label>
 				</p>
-				<input type="submit" value="', $txt['reminder_continue'], '" class="button_submit" />
-				<br class="clear" />
+				<div class="flow_auto">
+					<input type="submit" value="', $txt['reminder_continue'], '" class="button_submit" />
+					<input type="hidden" name="uid" value="', $context['current_member']['id'], '" />
+					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
+					<input type="hidden" name="', $context['remind_token_var'], '" value="', $context['remind_token'], '" />
+				</div>
 			</div>
 		</div>
-
-		<input type="hidden" name="uid" value="', $context['current_member']['id'], '" />
-		<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-		<input type="hidden" name="', $context['remind_token_var'], '" value="', $context['remind_token'], '" />
 	</form>';
 }
 
@@ -170,13 +170,14 @@ function template_ask()
 
 	echo '
 				</dl>
-				<p class="align_center"><input type="submit" value="', $txt['save'], '" class="button_submit" /></p>
+				<div class="auto_flow">
+					<input type="submit" value="', $txt['save'], '" class="button_submit" />
+					<input type="hidden" name="uid" value="', $context['remind_user'], '" />
+					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
+					<input type="hidden" name="', $context['remind-sai_token_var'], '" value="', $context['remind-sai_token'], '" />
+				</div>
 			</div>
 		</div>
-		<br class="clear" />
-		<input type="hidden" name="uid" value="', $context['remind_user'], '" />
-		<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-		<input type="hidden" name="', $context['remind-sai_token_var'], '" value="', $context['remind-sai_token'], '" />
 	</form>';
 
 	if ($context['account_type'] == 'password')

+ 19 - 18
Themes/default/Search.template.php

@@ -155,7 +155,9 @@ function template_main()
 			<div class="roundframe">
 				<div class="title_bar">
 					<h4 class="titlebg">
-						<a href="javascript:void(0);" onclick="expandCollapseBoards(); return false;"><img src="', $settings['images_url'], '/expand.png" id="expandBoardsIcon" alt=""  class="icon"/></a>
+						<span class="floatright">
+							<a href="javascript:void(0);" onclick="expandCollapseBoards(); return false;"><img src="', $settings['images_url'], '/expand.png" id="expandBoardsIcon" alt=""  class="icon"/></a>
+						</span>
 						<span>
 							<a href="javascript:void(0);" onclick="expandCollapseBoards(); return false;"><strong>', $txt['choose_board'], '</strong></a>
 						</span>
@@ -186,7 +188,9 @@ function template_main()
 
 			echo '
 								<li class="board" style="margin-', $context['right_to_left'] ? 'right' : 'left', ': ', $board['child_level'], 'em;">
-									<label for="brd', $board['id'], '"><input type="checkbox" id="brd', $board['id'], '" name="brd[', $board['id'], ']" value="', $board['id'], '"', $board['selected'] ? ' checked="checked"' : '', ' class="input_check" /> ', $board['name'], '</label>
+									<label for="brd', $board['id'], '">
+										<input type="checkbox" id="brd', $board['id'], '" name="brd[', $board['id'], ']" value="', $board['id'], '"', $board['selected'] ? ' checked="checked"' : '', ' class="input_check" /> ', $board['name'], '
+									</label>
 								</li>';
 
 			$i ++;
@@ -203,12 +207,11 @@ function template_main()
 				<br class="clear" />';
 
 			echo '
-				<div class="padding">
+				<div class="padding flow_auto">
 					<input type="checkbox" name="all" id="check_all" value=""', $context['boards_check_all'] ? ' checked="checked"' : '', ' onclick="invertAll(this, this.form, \'brd\');" class="input_check floatleft" />
 					<label for="check_all" class="floatleft"><em>', $txt['check_all'], '</em></label>
 					<input type="submit" name="b_search" value="', $txt['search'], '" class="button_submit" />
 				</div>
-				<br class="clear_right" />
 			</div>
 		</fieldset>';
 		}
@@ -260,17 +263,16 @@ function template_results()
 						<input type="text" name="search"', !empty($context['search_params']['search']) ? ' value="' . $context['search_params']['search'] . '"' : '', ' maxlength="', $context['search_string_limit'], '" size="40" class="input_text" />
 					</dd>
 				</dl>
-
-				<input type="submit" name="edit_search" value="', $txt['search_adjust_submit'], '" class="button_submit" />
-				<br class="clear_right" />
-				<input type="hidden" name="searchtype" value="', !empty($context['search_params']['searchtype']) ? $context['search_params']['searchtype'] : 0, '" />
-				<input type="hidden" name="userspec" value="', !empty($context['search_params']['userspec']) ? $context['search_params']['userspec'] : '', '" />
-				<input type="hidden" name="show_complete" value="', !empty($context['search_params']['show_complete']) ? 1 : 0, '" />
-				<input type="hidden" name="subject_only" value="', !empty($context['search_params']['subject_only']) ? 1 : 0, '" />
-				<input type="hidden" name="minage" value="', !empty($context['search_params']['minage']) ? $context['search_params']['minage'] : '0', '" />
-				<input type="hidden" name="maxage" value="', !empty($context['search_params']['maxage']) ? $context['search_params']['maxage'] : '9999', '" />
-				<input type="hidden" name="sort" value="', !empty($context['search_params']['sort']) ? $context['search_params']['sort'] : 'relevance', '" />';
-
+				<div class="flow_auto" >
+					<input type="submit" name="edit_search" value="', $txt['search_adjust_submit'], '" class="button_submit" />
+					<input type="hidden" name="searchtype" value="', !empty($context['search_params']['searchtype']) ? $context['search_params']['searchtype'] : 0, '" />
+					<input type="hidden" name="userspec" value="', !empty($context['search_params']['userspec']) ? $context['search_params']['userspec'] : '', '" />
+					<input type="hidden" name="show_complete" value="', !empty($context['search_params']['show_complete']) ? 1 : 0, '" />
+					<input type="hidden" name="subject_only" value="', !empty($context['search_params']['subject_only']) ? 1 : 0, '" />
+					<input type="hidden" name="minage" value="', !empty($context['search_params']['minage']) ? $context['search_params']['minage'] : '0', '" />
+					<input type="hidden" name="maxage" value="', !empty($context['search_params']['maxage']) ? $context['search_params']['maxage'] : '9999', '" />
+					<input type="hidden" name="sort" value="', !empty($context['search_params']['sort']) ? $context['search_params']['sort'] : 'relevance', '" />
+				</div>';
 		if (!empty($context['search_params']['brd']))
 			foreach ($context['search_params']['brd'] as $board_id)
 				echo '
@@ -394,7 +396,7 @@ function template_results()
 		{
 			echo '
 			<div class="titlebg2" style="padding: 4px;">
-				<div class="floatright">
+				<div class="floatright flow_auto">
 					<select class="qaction" name="qaction"', $context['can_move'] ? ' onchange="this.form.move_to.disabled = (this.options[this.selectedIndex].value != \'move\');"' : '', '>
 						<option value="">--------</option>';
 
@@ -412,9 +414,8 @@ function template_results()
 
 			echo '
 					<input type="hidden" name="redirect_url" value="', $scripturl . '?action=search2;params=' . $context['params'], '" />
-					<input type="submit" style="font-size: 0.8em;" value="', $txt['quick_mod_go'], '" onclick="return this.form.qaction.value != \'\' &amp;&amp; confirm(\'', $txt['quickmod_confirm'], '\');" class="button_submit" />
+					<input type="submit" value="', $txt['quick_mod_go'], '" onclick="return this.form.qaction.value != \'\' &amp;&amp; confirm(\'', $txt['quickmod_confirm'], '\');" class="button_submit" style="float: none;font-size: .8em;"/>
 				</div>
-				<br class="clear" />
 			</div>';
 		}
 

+ 10 - 12
Themes/default/SendTopic.template.php

@@ -89,15 +89,14 @@ function template_main()
 							</dd>
 						</dl>
 					</fieldset>
-					<div class="righttext">
+					<div class="flow_auto">
 						<input type="submit" name="send" value="', $txt['sendtopic_send'], '" class="button_submit" />
+						<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 					</div>
 				</div>
 			</div>
-			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // Send an email to a user!
@@ -178,8 +177,9 @@ function template_custom_email()
 						</dd>
 					</dl>
 					<hr class="hrcolor" />
-					<input type="submit" name="send" value="', $txt['sendtopic_send'], '" class="button_submit" />
-					<br class="clear_right" />
+					<div class="flow_auto">
+						<input type="submit" name="send" value="', $txt['sendtopic_send'], '" class="button_submit" />
+					</div>
 				</div>
 			</div>';
 
@@ -190,8 +190,7 @@ function template_custom_email()
 	echo '
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_report()
@@ -224,7 +223,7 @@ function template_report()
 	}
 
 	echo '
-						<p>', $txt['report_to_mod_func'], '</p>
+						<p class="noticebox">', $txt['report_to_mod_func'], '</p>
 						<br />
 						<dl class="settings" id="report_post">';
 
@@ -260,13 +259,12 @@ function template_report()
 
 	echo '
 						</dl>
-						<div class="righttext">
+						<div class="flow_auto">
 							<input type="submit" name="save" value="', $txt['rtm10'], '" style="margin-left: 1ex;" class="button_submit" />
+							<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 						</div>
 					</div>
-					<br class="clear" />
 				</div>
-			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 		</form>
 	</div>';
 }

+ 73 - 73
Themes/default/SplitTopics.template.php

@@ -39,10 +39,11 @@ function template_ask()
 						</li>
 					</ul>
 					<hr class="hrcolor" />
-					<input type="submit" value="', $txt['split'], '" class="button_submit" />
-					<br class="clear_right" />
+					<div class="auto_flow">
+						<input type="submit" value="', $txt['split'], '" class="button_submit" />
+						<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
+					</div>
 				</div>
-				<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 			</div>
 		</form>
 	</div>';
@@ -145,86 +146,86 @@ function template_select()
 				</ul>
 			</div>
 			<br class="clear" />
-			<p>
+			<div class="flow_auto">
 				<input type="hidden" name="topic" value="', $context['current_topic'], '" />
 				<input type="hidden" name="subname" value="', $context['new_subject'], '" />
 				<input type="submit" value="', $txt['split'], '" class="button_submit" />
 				<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-			</p>
+			</div>
 		</form>
 	</div>
-	<br class="clear" />
-		<script type="text/javascript"><!-- // --><![CDATA[
-			var start = new Array();
-			start[0] = ', $context['not_selected']['start'], ';
-			start[1] = ', $context['selected']['start'], ';
+	
+	<script type="text/javascript"><!-- // --><![CDATA[
+		var start = new Array();
+		start[0] = ', $context['not_selected']['start'], ';
+		start[1] = ', $context['selected']['start'], ';
 
-			function select(direction, msg_id)
+		function select(direction, msg_id)
+		{
+			if (window.XMLHttpRequest)
 			{
-				if (window.XMLHttpRequest)
-				{
-					getXMLDocument(smf_prepareScriptUrl(smf_scripturl) + "action=splittopics;sa=selectTopics;subname=', $context['topic']['subject'], ';topic=', $context['topic']['id'], '." + start[0] + ";start2=" + start[1] + ";move=" + direction + ";msg=" + msg_id + ";xml", onDocReceived);
-					return false;
-				}
-				else
-					return true;
+				getXMLDocument(smf_prepareScriptUrl(smf_scripturl) + "action=splittopics;sa=selectTopics;subname=', $context['topic']['subject'], ';topic=', $context['topic']['id'], '." + start[0] + ";start2=" + start[1] + ";move=" + direction + ";msg=" + msg_id + ";xml", onDocReceived);
+				return false;
 			}
-			function onDocReceived(XMLDoc)
+			else
+				return true;
+		}
+		function onDocReceived(XMLDoc)
+		{
+			var i, j, pageIndex;
+			for (i = 0; i < 2; i++)
 			{
-				var i, j, pageIndex;
-				for (i = 0; i < 2; i++)
-				{
-					pageIndex = XMLDoc.getElementsByTagName("pageIndex")[i];
-					setInnerHTML(document.getElementById("pageindex_" + pageIndex.getAttribute("section")), pageIndex.firstChild.nodeValue);
-					start[i] = pageIndex.getAttribute("startFrom");
-				}
-				var numChanges = XMLDoc.getElementsByTagName("change").length;
-				var curChange, curSection, curAction, curId, curList, curData, newItem, sInsertBeforeId;
-				for (i = 0; i < numChanges; i++)
+				pageIndex = XMLDoc.getElementsByTagName("pageIndex")[i];
+				setInnerHTML(document.getElementById("pageindex_" + pageIndex.getAttribute("section")), pageIndex.firstChild.nodeValue);
+				start[i] = pageIndex.getAttribute("startFrom");
+			}
+			var numChanges = XMLDoc.getElementsByTagName("change").length;
+			var curChange, curSection, curAction, curId, curList, curData, newItem, sInsertBeforeId;
+			for (i = 0; i < numChanges; i++)
+			{
+				curChange = XMLDoc.getElementsByTagName("change")[i];
+				curSection = curChange.getAttribute("section");
+				curAction = curChange.getAttribute("curAction");
+				curId = curChange.getAttribute("id");
+				curList = document.getElementById("messages_" + curSection);
+				if (curAction == "remove")
+					curList.removeChild(document.getElementById(curSection + "_" + curId));
+				// Insert a message.
+				else
 				{
-					curChange = XMLDoc.getElementsByTagName("change")[i];
-					curSection = curChange.getAttribute("section");
-					curAction = curChange.getAttribute("curAction");
-					curId = curChange.getAttribute("id");
-					curList = document.getElementById("messages_" + curSection);
-					if (curAction == "remove")
-						curList.removeChild(document.getElementById(curSection + "_" + curId));
-					// Insert a message.
-					else
+					// By default, insert the element at the end of the list.
+					sInsertBeforeId = null;
+					// Loop through the list to try and find an item to insert after.
+					oListItems = curList.getElementsByTagName("LI");
+					for (j = 0; j < oListItems.length; j++)
 					{
-						// By default, insert the element at the end of the list.
-						sInsertBeforeId = null;
-						// Loop through the list to try and find an item to insert after.
-						oListItems = curList.getElementsByTagName("LI");
-						for (j = 0; j < oListItems.length; j++)
+						if (parseInt(oListItems[j].id.substr(curSection.length + 1)) < curId)
 						{
-							if (parseInt(oListItems[j].id.substr(curSection.length + 1)) < curId)
-							{
-								// This would be a nice place to insert the row.
-								sInsertBeforeId = oListItems[j].id;
-								// We\'re done for now. Escape the loop.
-								j = oListItems.length + 1;
-							}
+							// This would be a nice place to insert the row.
+							sInsertBeforeId = oListItems[j].id;
+							// We\'re done for now. Escape the loop.
+							j = oListItems.length + 1;
 						}
+					}
 
-						// Let\'s create a nice container for the message.
-						newItem = document.createElement("LI");
-						newItem.className = "windowbg2";
-						newItem.id = curSection + "_" + curId;
-						newItem.innerHTML = "<div class=\\"content\\"><div class=\\"message_header\\"><a class=\\"split_icon float" + (curSection == "selected" ? "left" : "right") + "\\" href=\\"" + smf_prepareScriptUrl(smf_scripturl) + "action=splittopics;sa=selectTopics;subname=', $context['topic']['subject'], ';topic=', $context['topic']['id'], '.', $context['not_selected']['start'], ';start2=', $context['selected']['start'], ';move=" + (curSection == "selected" ? "up" : "down") + ";msg=" + curId + "\\" onclick=\\"return select(\'" + (curSection == "selected" ? "up" : "down") + "\', " + curId + ");\\"><img src=\\"', $settings['images_url'], '/split_" + (curSection == "selected" ? "de" : "") + "select.png\\" alt=\\"" + (curSection == "selected" ? "&lt;-" : "-&gt;") + "\\" /></a><strong>" + curChange.getElementsByTagName("subject")[0].firstChild.nodeValue + "</strong> ', $txt['by'], ' <strong>" + curChange.getElementsByTagName("poster")[0].firstChild.nodeValue + "</strong><br /><em>" + curChange.getElementsByTagName("time")[0].firstChild.nodeValue + "</em></div><div class=\\"post\\">" + curChange.getElementsByTagName("body")[0].firstChild.nodeValue + "</div></div>";
+					// Let\'s create a nice container for the message.
+					newItem = document.createElement("LI");
+					newItem.className = "windowbg2";
+					newItem.id = curSection + "_" + curId;
+					newItem.innerHTML = "<div class=\\"content\\"><div class=\\"message_header\\"><a class=\\"split_icon float" + (curSection == "selected" ? "left" : "right") + "\\" href=\\"" + smf_prepareScriptUrl(smf_scripturl) + "action=splittopics;sa=selectTopics;subname=', $context['topic']['subject'], ';topic=', $context['topic']['id'], '.', $context['not_selected']['start'], ';start2=', $context['selected']['start'], ';move=" + (curSection == "selected" ? "up" : "down") + ";msg=" + curId + "\\" onclick=\\"return select(\'" + (curSection == "selected" ? "up" : "down") + "\', " + curId + ");\\"><img src=\\"', $settings['images_url'], '/split_" + (curSection == "selected" ? "de" : "") + "select.png\\" alt=\\"" + (curSection == "selected" ? "&lt;-" : "-&gt;") + "\\" /></a><strong>" + curChange.getElementsByTagName("subject")[0].firstChild.nodeValue + "</strong> ', $txt['by'], ' <strong>" + curChange.getElementsByTagName("poster")[0].firstChild.nodeValue + "</strong><br /><em>" + curChange.getElementsByTagName("time")[0].firstChild.nodeValue + "</em></div><div class=\\"post\\">" + curChange.getElementsByTagName("body")[0].firstChild.nodeValue + "</div></div>";
 
-						// So, where do we insert it?
-						if (typeof sInsertBeforeId == "string")
-							curList.insertBefore(newItem, document.getElementById(sInsertBeforeId));
-						else
-							curList.appendChild(newItem);
-					}
+					// So, where do we insert it?
+					if (typeof sInsertBeforeId == "string")
+						curList.insertBefore(newItem, document.getElementById(sInsertBeforeId));
+					else
+						curList.appendChild(newItem);
 				}
-				// After all changes, make sure the window backgrounds are still correct for both lists.
-				applyWindowClasses(document.getElementById("messages_selected"));
-				applyWindowClasses(document.getElementById("messages_not_selected"));
 			}
-		// ]]></script>';
+			// After all changes, make sure the window backgrounds are still correct for both lists.
+			applyWindowClasses(document.getElementById("messages_selected"));
+			applyWindowClasses(document.getElementById("messages_not_selected"));
+		}
+	// ]]></script>';
 }
 
 function template_merge_done()
@@ -342,8 +343,7 @@ function template_merge()
 			<div class="pagesection">
 				<strong>', $txt['pages'], ':</strong> ', $context['page_index'], '
 			</div>
-		</div>
-	<br class="clear" />';
+		</div>';
 }
 
 function template_merge_extra_options()
@@ -444,15 +444,15 @@ function template_merge_extra_options()
 					</fieldset>';
 	}
 	echo '
-					<input type="submit" value="' . $txt['merge'] . '" class="button_submit" />
-					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-					<input type="hidden" name="sa" value="execute" />
-					<br class="clear_right" />
+					<div class="auto_flow">
+						<input type="submit" value="' . $txt['merge'] . '" class="button_submit" />
+						<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
+						<input type="hidden" name="sa" value="execute" />
+					</div>
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 ?>

+ 24 - 41
Themes/default/Themes.template.php

@@ -89,11 +89,10 @@ function template_main()
 					</dl>
 					<hr class="hrcolor" />
 					<input type="submit" name="save" value="' . $txt['save'] . '" class="button_submit" />
-					<br class="clear_right" />
+					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
+					<input type="hidden" name="', $context['admin-tm_token_var'], '" value="', $context['admin-tm_token'], '" />
 				</div>
 			</div>
-			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-			<input type="hidden" name="', $context['admin-tm_token_var'], '" value="', $context['admin-tm_token'], '" />
 		</form>';
 
 	// Link to simplemachines.org for latest themes and info!
@@ -161,21 +160,19 @@ function template_main()
 					</dl>
 					<hr class="hrcolor" />
 					<input type="submit" name="save" value="', $txt['theme_install_go'], '" class="button_submit" />
-					<br class="clear_right" />
+					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
+					<input type="hidden" name="', $context['admin-tm_token_var'], '" value="', $context['admin-tm_token'], '" />
 				</div>
 			</div>
-			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-			<input type="hidden" name="', $context['admin-tm_token_var'], '" value="', $context['admin-tm_token'], '" />
 		</form>
 	</div>
-	<br class="clear" />
 
-		<script type="text/javascript"><!-- // --><![CDATA[
-			window.smfForum_scripturl = "', $scripturl, '";
-			window.smfForum_sessionid = "', $context['session_id'], '";
-			window.smfForum_sessionvar = "', $context['session_var'], '";
-			window.smfThemes_writable = ', $context['can_create_new'] ? 'true' : 'false', ';
-		// ]]></script>';
+	<script type="text/javascript"><!-- // --><![CDATA[
+		window.smfForum_scripturl = "', $scripturl, '";
+		window.smfForum_sessionid = "', $context['session_id'], '";
+		window.smfForum_sessionvar = "', $context['session_var'], '";
+		window.smfThemes_writable = ', $context['can_create_new'] ? 'true' : 'false', ';
+	// ]]></script>';
 
 	if (empty($modSettings['disable_smf_js']))
 		echo '
@@ -254,15 +251,13 @@ function template_list_themes()
 						</dd>
 					</dl>
 					<input type="submit" name="save" value="', $txt['themeadmin_list_reset_go'], '" class="button_submit" />
-					<br class="clear_right" />
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 					<input type="hidden" name="', $context['admin-tl_token_var'], '" value="', $context['admin-tl_token'], '" />
 				</div>
 			</div>
 
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_reset_list()
@@ -307,8 +302,7 @@ function template_reset_list()
 	}
 
 	echo '
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_set_options()
@@ -405,12 +399,10 @@ function template_set_options()
 					<hr class="hrcolor" />
 					<input type="submit" name="submit" value="', $txt['save'], '" class="button_submit" />
 					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-					<br class="clear_right" />
 				</div>
 			</div>
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_set_settings()
@@ -606,15 +598,13 @@ function template_set_settings()
 	echo '
 					</dl>
 					<hr class="hrcolor" />
-					<input type="submit" name="save" value="', $txt['save'], '" class="button_submit" /><br />
-					<br class="clear_right" />
+					<input type="submit" name="save" value="', $txt['save'], '" class="button_submit" />
+					<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
+					<input type="hidden" name="', $context['admin-sts_token_var'], '" value="', $context['admin-sts_token'], '" />
 				</div>
 			</div>
-			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
-			<input type="hidden" name="', $context['admin-sts_token_var'], '" value="', $context['admin-sts_token'], '" />
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 
 	if (!empty($context['theme_variants']))
 	{
@@ -728,8 +718,7 @@ function template_pick()
 
 	echo '
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // Okay, that theme was installed successfully!
@@ -753,8 +742,7 @@ function template_installed()
 				</p>
 			</div>
 		</div>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_edit_list()
@@ -792,8 +780,7 @@ function template_edit_list()
 	}
 
 	echo '
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_copy_template()
@@ -836,8 +823,7 @@ function template_copy_template()
 				</ul>
 			</div>
 		</div>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 function template_edit_browse()
@@ -885,8 +871,7 @@ function template_edit_browse()
 	echo '
 		</tbody>
 		</table>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // Wanna edit the stylesheet?
@@ -1039,8 +1024,7 @@ function template_edit_style()
 			<input type="hidden" name="filename" value="', $context['edit_filename'], '" />
 			<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 // This edits the template...
@@ -1135,8 +1119,7 @@ function template_edit_file()
 			</div>
 
 		</form>
-	</div>
-	<br class="clear" />';
+	</div>';
 }
 
 ?>

+ 19 - 6
Themes/default/css/index.css

@@ -157,7 +157,6 @@ input:focus, textarea:focus, button:focus, select:focus, textarea.editor:focus {
 	border-radius: 3px;
 }*/
 a.button_link {
- 
 	color: #333;
 	margin: 0 !important;
 }
@@ -260,7 +259,9 @@ em {
 .floatleft {
 	float: left;
 }
-
+.floatnone {
+	float: none;
+}
 .flow_auto {
 	overflow: auto;
 }
@@ -908,7 +909,7 @@ img.sort {
 #permissions table.table_grid  td {
 	padding: 5px 10px;
 	cursor: default;
-} 
+}
 
 .postbg {
 	border-left: 1px solid #7f7f7f;
@@ -2841,6 +2842,17 @@ tr.windowbg td, tr.windowbg2 td, tr.approvebg td, tr.highlight2 td {
 	background-image: none;
 }
 
+.errorfile_table {
+	background: #f0f4f7;
+	border-spacing: 3;
+	border-collapse: collapse;
+}
+.errorfile_table td.current {
+	font-weight: bold;
+	border: 1px solid black;
+	border-width: 1px 0 1px 1px;
+}
+
 /* Styles for (fatal) errors.
 ------------------------------------------------- */
 
@@ -3049,7 +3061,8 @@ dl {
 	border: solid #666;
 	border-width: 1px 1px 1px 1px;
 	border-left: none;
-	border-right: none; background: #eee;
+	border-right: none;
+	background: #eee;
 	text-align: center;
 }
 .activity_stats li.last span {
@@ -3262,12 +3275,12 @@ img.centericon {
 #stats_left, #top_posters, #top_topics_replies, #top_topics_starter {
 	float: left;
 	width: 50%;
-	padding: 0 3px 0 0; 
+	padding: 0 3px 0 0;
 }
 #stats_right, #top_boards, #top_topics_views, #most_online {
 	float: right;
 	width: 50%;
-	padding: 0 0 0 3px; 
+	padding: 0 0 0 3px;
 }
 #stats_left{
 	border-right: 1px solid #bbb;

+ 19 - 19
Themes/default/languages/Admin.english.php

@@ -19,13 +19,13 @@ $txt['admin_template_edit'] = 'Edit your forum template';
 $txt['admin_modifications'] = 'Modification Settings';
 $txt['admin_security_moderation'] = 'Security and Moderation';
 $txt['admin_server_settings'] = 'Server Settings';
-$txt['admin_reserved_set'] = 'Set Reserved Names';
+$txt['admin_reserved_set'] = 'Set reserved names';
 $txt['admin_reserved_line'] = 'One reserved word per line.';
 $txt['admin_basic_settings'] = 'This page allows you to change the basic settings for your forum.  Be very careful with these settings, as they may render the forum dysfunctional.';
 $txt['admin_maintain'] = 'Enable Maintenance Mode';
 $txt['admin_title'] = 'Forum Title';
 $txt['admin_url'] = 'Forum URL';
-$txt['cookie_name'] = 'Cookie Name';
+$txt['cookie_name'] = 'Cookie name';
 $txt['admin_webmaster_email'] = 'Webmaster email address';
 $txt['boarddir'] = 'SMF Directory';
 $txt['sourcesdir'] = 'Sources Directory';
@@ -81,8 +81,8 @@ $txt['errors_fixing'] = 'Fixing forum errors';
 $txt['errors_fixed'] = 'All errors fixed. Please check on any categories, boards, or topics created to decide what to do with them.';
 $txt['attachments_avatars'] = 'Attachments and Avatars';
 $txt['attachments_desc'] = 'From here you can administer the attached files on your system. You can delete attachments by size and by date from your system. Statistics on attachments are also displayed below.';
-$txt['attachment_stats'] = 'File Attachment Statistics';
-$txt['attachment_integrity_check'] = 'Attachment Integrity Check';
+$txt['attachment_stats'] = 'File attachment statistics';
+$txt['attachment_integrity_check'] = 'Attachment integrity check';
 $txt['attachment_integrity_check_desc'] = 'This function will check the integrity and sizes of attachments and filenames listed in the database and, if necessary, fix errors it encounters.';
 $txt['attachment_check_now'] = 'Run check now';
 $txt['attachment_pruning'] = 'Attachment Pruning';
@@ -97,7 +97,7 @@ $txt['attachment_options'] = 'File attachment options';
 $txt['attachment_log'] = 'Attachment log';
 $txt['attachment_remove_old'] = 'Remove attachments older than';
 $txt['attachment_remove_size'] = 'Remove attachments larger than';
-$txt['attachment_name'] = 'Attachment Name';
+$txt['attachment_name'] = 'Attachment name';
 $txt['attachment_file_size'] = 'File Size';
 $txt['attachmentdir_size_not_set'] = 'No maximum directory size is currently set';
 $txt['attachment_delete_admin'] = '[attachment deleted by admin]';
@@ -245,7 +245,7 @@ $txt['db_persist'] = 'Use a persistent connection';
 $txt['ssi_db_user'] = 'Database username to use in SSI mode';
 $txt['ssi_db_passwd'] = 'Database password to use in SSI mode';
 
-$txt['default_language'] = 'Default Forum Language';
+$txt['default_language'] = 'Default forum language';
 
 $txt['maintenance_subject'] = 'Subject for display';
 $txt['maintenance_message'] = 'Message for display';
@@ -266,7 +266,7 @@ $txt['dvc_languages'] = 'Language Files';
 $txt['smileys_default_set_for_theme'] = 'Select default smiley set for this theme';
 $txt['smileys_no_default'] = '(use global default smiley set)';
 
-$txt['censor_test'] = 'Test Censored Words';
+$txt['censor_test'] = 'Test censored words';
 $txt['censor_test_save'] = 'Test';
 $txt['censor_case'] = 'Ignore case when censoring';
 $txt['censor_whole_words'] = 'Check only whole words';
@@ -305,7 +305,7 @@ $txt['support_resources'] = 'Support Resources';
 $txt['support_resources_p1'] = 'Our <a href="%1$s">Online Manual</a> provides the main documentation for SMF. The SMF Online Manual has many documents to help answer support questions and explain <a href="%2$s">Features</a>, <a href="%3$s">Settings</a>, <a href="%4$s">Themes</a>, <a href="%5$s">Packages</a>, etc. The Online Manual documents each area of SMF thoroughly and should answer most questions quickly.';
 $txt['support_resources_p2'] = 'If you can\'t find the answers to your questions in the Online Manual, you may want to search our <a href="%1$s">Support Community</a> or ask for assistance in either our <a href="%2$s">English</a> or one of our many <a href="%3$s">international support boards</a>. The SMF Support Community can be used for <a href="%4$s">support</a>, <a href="%5$s">customization</a>, and many other things such as discussing SMF, finding a host, and discussing administrative issues with other forum administrators.';
 
-$txt['support_latest'] = 'Common Support &amp; Issues';
+$txt['support_latest'] = 'Common support &amp; issues';
 $txt['support_latest_fetch'] = 'Retrieving support information...';
 
 $txt['edit_permissions_info'] = 'Change restrictions and available features, globally or in specific boards.';
@@ -372,7 +372,7 @@ $txt['attachment_thumb_memory_note1'] = 'Leave this unchecked to always attempt
 $txt['attachmentThumbWidth'] = 'Maximum width of thumbnails';
 $txt['attachmentThumbHeight'] = 'Maximum height of thumbnails';
 $txt['attachment_thumbnail_settings'] = 'Thumbnail Settings';
-$txt['attachment_security_settings'] = 'Attachment Security Settings';
+$txt['attachment_security_settings'] = 'Attachment security settings';
 
 $txt['attach_dir_does_not_exist'] = 'Does Not Exist';
 $txt['attach_dir_not_writable'] = 'Not Writable';
@@ -399,10 +399,10 @@ $txt['attach_dir_is_current_bd'] = 'Unable to remove while it is selected as the
 $txt['attach_last_dir'] = 'Last active attachment directory';
 $txt['attach_current_dir'] = 'Current attachment directory';
 $txt['attach_current'] = 'Current';
-$txt['attach_path_manage'] = 'Manage Attachment Paths';
+$txt['attach_path_manage'] = 'Manage attachment paths';
 $txt['attach_directories'] = 'Attachment Directories';
-$txt['attach_paths'] = 'Attachment Directory Paths';
-$txt['attach_base_paths'] = 'Base Directory Paths';
+$txt['attach_paths'] = 'Attachment directory paths';
+$txt['attach_base_paths'] = 'Base directory paths';
 $txt['attach_path'] = 'Path';
 $txt['attach_current_size'] = 'Size (KB)';
 $txt['attach_num_files'] = 'Files';
@@ -411,7 +411,7 @@ $txt['attach_add_path'] = 'Add Path';
 $txt['attach_path_current_bad'] = 'Invalid current attachment path.';
 $txt['attachmentDirFileLimit'] = 'Maximum number of files per directory';
 
-$txt['attach_base_paths'] = 'Base Directory Paths';
+$txt['attach_base_paths'] = 'Base directory paths';
 $txt['attach_num_dirs'] = 'Directories';
 $txt['max_image_width'] = 'Max display width of posted or attached images';
 $txt['max_image_height'] = 'Max display height of posted or attached images';
@@ -525,7 +525,7 @@ $txt['manageposts_settings_submit'] = 'Save';
 
 $txt['manageposts_bbc_settings'] = 'Bulletin Board Code';
 $txt['manageposts_bbc_settings_description'] = 'Bulletin board code can be used to add markup to forum messages. For example, to highlight the word \'house\' you can type [b]house[/b]. All Bulletin board code tags are surrounded by square brackets (\'[\' and \']\').';
-$txt['manageposts_bbc_settings_title'] = 'Bulletin Board Code Settings';
+$txt['manageposts_bbc_settings_title'] = 'Bulletin Board Code settings';
 $txt['manageposts_bbc_settings_submit'] = 'Save';
 
 $txt['manageposts_topic_settings'] = 'Topic Settings';
@@ -616,7 +616,7 @@ $txt['admin_news_select_excluded_groups'] = 'Excluded Groups';
 $txt['admin_news_select_excluded_groups_desc'] = 'Select groups who should definitely not receive the newsletter.';
 $txt['admin_news_select_email'] = 'Email Addresses';
 $txt['admin_news_select_email_desc'] = 'A semi-colon separated list of email addresses which should be sent newsletter. (i.e. address1; address2)';
-$txt['admin_news_select_override_notify'] = 'Override Notification Settings';
+$txt['admin_news_select_override_notify'] = 'Override notification settings';
 // Use entities in below.
 $txt['admin_news_cannot_pm_emails_js'] = 'You cannot send a personal message to an email address. If you continue all entered email addresses will be ignored.\\n\\nAre you sure you wish to do this?';
 
@@ -653,7 +653,7 @@ $txt['core_settings_deactivation_message'] = 'The feature {core_feature} has bee
 $txt['core_settings_generic_error'] = 'An unforeseen error occurred, please relod the page and try again';
 
 $txt['boardsEdit'] = 'Modify Boards';
-$txt['mboards_new_cat'] = 'Create New Category';
+$txt['mboards_new_cat'] = 'Create new category';
 $txt['manage_holidays'] = 'Manage Holidays';
 $txt['calendar_settings'] = 'Calendar Settings';
 $txt['search_weights'] = 'Weights';
@@ -662,8 +662,8 @@ $txt['search_method'] = 'Search Method';
 $txt['smiley_sets'] = 'Smiley Sets';
 $txt['smileys_add'] = 'Add Smiley';
 $txt['smileys_edit'] = 'Edit Smileys';
-$txt['smileys_set_order'] = 'Set Smiley Order';
-$txt['icons_edit_message_icons'] = 'Edit Message Icons';
+$txt['smileys_set_order'] = 'Set Smiley order';
+$txt['icons_edit_message_icons'] = 'Edit message icons';
 
 $txt['membergroups_new_group'] = 'Add Membergroup';
 $txt['membergroups_edit_groups'] = 'Edit Membergroups';
@@ -681,7 +681,7 @@ $txt['themeadmin_admin_title'] = 'Manage and Install';
 $txt['themeadmin_list_title'] = 'Theme Settings';
 $txt['themeadmin_reset_title'] = 'Member Options';
 $txt['themeadmin_edit_title'] = 'Modify Themes';
-$txt['admin_browse_register_new'] = 'Register New Member';
+$txt['admin_browse_register_new'] = 'Register new member';
 
 $txt['search_engines'] = 'Search Engines';
 $txt['spiders'] = 'Spiders';

+ 7 - 7
Themes/default/languages/ManageMail.english.php

@@ -10,21 +10,21 @@ $txt['smtp_port'] = 'SMTP port';
 $txt['smtp_username'] = 'SMTP username';
 $txt['smtp_password'] = 'SMTP password';
 
-$txt['mail_queue'] = 'Enable Mail Queue';
+$txt['mail_queue'] = 'Enable mail queue';
 $txt['mail_limit'] = 'Maximum emails to send per minute';
 $txt['mail_limit_desc'] = '(Set to 0 to disable)';
 $txt['mail_quantity'] = 'Maximum amount of emails to send per page load';
 
-$txt['mailqueue_stats'] = 'Mail Queue Statistics';
+$txt['mailqueue_stats'] = 'Mail queue statistics';
 $txt['mailqueue_oldest'] = 'Oldest Mail';
 $txt['mailqueue_oldest_not_available'] = 'N/A';
-$txt['mailqueue_size'] = 'Queue Length';
+$txt['mailqueue_size'] = 'Queue length';
 
 $txt['mailqueue_age'] = 'Age';
 $txt['mailqueue_priority'] = 'Priority';
 $txt['mailqueue_recipient'] = 'Recipient';
 $txt['mailqueue_subject'] = 'Subject';
-$txt['mailqueue_clear_list'] = 'Send Mail Queue Now';
+$txt['mailqueue_clear_list'] = 'Send mail queue now';
 $txt['mailqueue_no_items'] = 'The mail queue is currently empty';
 // Do not use numeric entities in below string.
 $txt['mailqueue_clear_list_warning'] = 'Are you sure you wish to send the whole mail queue now? This will override any limits you have set.';
@@ -44,7 +44,7 @@ $txt['mq_mpriority_3'] = 'Normal';
 $txt['mq_mpriority_2'] = 'High';
 $txt['mq_mpriority_1'] = 'Very High';
 
-$txt['birthday_email'] = 'Birthday Message to use';
-$txt['birthday_body'] = 'Email Body';
-$txt['birthday_subject'] = 'Email Subject';
+$txt['birthday_email'] = 'Birthday message to use';
+$txt['birthday_body'] = 'Email body';
+$txt['birthday_subject'] = 'Email subject';
 ?>

+ 4 - 4
Themes/default/languages/ManageMaintenance.english.php

@@ -99,7 +99,7 @@ $txt['error_url'] = 'URL of page causing the error';
 $txt['error_message'] = 'Error message';
 $txt['clear_filter'] = 'Clear filter';
 $txt['remove_selection'] = 'Remove Selection';
-$txt['remove_filtered_results'] = 'Remove All Filtered Results';
+$txt['remove_filtered_results'] = 'Remove all filtered results';
 $txt['sure_about_errorlog_remove'] = 'Are you sure you want to completely clear the error log?';
 $txt['remove_selection_confirm'] = 'Are you sure you want to delete the selected entries?';
 $txt['remove_filtered_results_confirm'] = 'Are you sure you want to delete the filtered entries?';
@@ -152,12 +152,12 @@ $txt['maintain_old_nothing_else'] = 'Any sort of topic.';
 $txt['maintain_old_are_moved'] = 'Moved topic notices.';
 $txt['maintain_old_are_locked'] = 'Locked.';
 $txt['maintain_old_are_not_stickied'] = 'But don\'t count stickied topics.';
-$txt['maintain_old_all'] = 'All Boards (click to select specific boards)';
-$txt['maintain_old_choose'] = 'Specific Boards (click to select all)';
+$txt['maintain_old_all'] = 'All boards (click to select specific boards)';
+$txt['maintain_old_choose'] = 'Specific boards (click to select all)';
 $txt['maintain_old_remove'] = 'Remove now';
 $txt['maintain_old_confirm'] = 'Are you really sure you want to delete old posts now?\\n\\nThis cannot be undone!';
 
-$txt['maintain_old_drafts'] = 'Remove Old Drafts';
+$txt['maintain_old_drafts'] = 'Remove old drafts';
 $txt['maintain_old_drafts_days'] = 'Remove all drafts older than';
 $txt['maintain_old_drafts_confirm'] = 'Are you really sure you want to delete old drafts now?\\n\\nThis cannot be undone!';
 $txt['maintain_members'] = 'Remove Inactive Members';

+ 10 - 10
Themes/default/languages/ManageMembers.english.php

@@ -32,13 +32,13 @@ $txt['membergroups_edit_inherit_permissions_no'] = 'No - Use Unique Permissions'
 $txt['membergroups_edit_inherit_permissions_from'] = 'Inherit From';
 $txt['membergroups_edit_hidden'] = 'Visibility';
 $txt['membergroups_edit_hidden_no'] = 'Visible';
-$txt['membergroups_edit_hidden_boardindex'] = 'Visible - Except in Group Key';
+$txt['membergroups_edit_hidden_boardindex'] = 'Visible - Apart from in group key';
 $txt['membergroups_edit_hidden_all'] = 'Invisible';
 // Do not use numeric entities in the below string.
 $txt['membergroups_edit_hidden_warning'] = 'Are you sure you want to disallow assignment of this group as a users primary group?\\n\\nDoing so will restrict assignment to additional groups only, and will update all current &quot;primary&quot; members to have it as an additional group only.';
 $txt['membergroups_edit_desc'] = 'Group description';
-$txt['membergroups_edit_group_type'] = 'Group Type';
-$txt['membergroups_edit_select_group_type'] = 'Select Group Type';
+$txt['membergroups_edit_group_type'] = 'Group type';
+$txt['membergroups_edit_select_group_type'] = 'Select Group type';
 $txt['membergroups_group_type_private'] = 'Private <span class="smalltext">(Membership must be assigned)</span>';
 $txt['membergroups_group_type_protected'] = 'Protected <span class="smalltext">(Only administrators can manage and assign)</span>';
 $txt['membergroups_group_type_request'] = 'Requestable <span class="smalltext">(User may request membership)</span>';
@@ -105,14 +105,14 @@ $txt['admin_browse_w_reject'] = 'Reject';
 $txt['admin_browse_w_remind'] = 'Remind';
 $txt['admin_browse_w_approve_deletion'] = 'Approve (Delete Accounts)';
 $txt['admin_browse_w_email'] = 'and send email';
-$txt['admin_browse_w_approve_require_activate'] = 'Approve and Require Activation';
+$txt['admin_browse_w_approve_require_activate'] = 'Approve and require activation';
 
 $txt['admin_browse_filter_by'] = 'Filter By';
 $txt['admin_browse_filter_show'] = 'Displaying';
-$txt['admin_browse_filter_type_0'] = 'Unactivated New Accounts';
-$txt['admin_browse_filter_type_2'] = 'Unactivated Email Changes';
-$txt['admin_browse_filter_type_3'] = 'Unapproved New Accounts';
-$txt['admin_browse_filter_type_4'] = 'Unapproved Account Deletions';
+$txt['admin_browse_filter_type_0'] = 'Unactivated new accounts';
+$txt['admin_browse_filter_type_2'] = 'Unactivated email changes';
+$txt['admin_browse_filter_type_3'] = 'Unapproved new accounts';
+$txt['admin_browse_filter_type_4'] = 'Unapproved account deletions';
 $txt['admin_browse_filter_type_5'] = 'Unapproved "Under Age" Accounts';
 
 $txt['admin_browse_outstanding'] = 'Outstanding Members';
@@ -121,8 +121,8 @@ $txt['admin_browse_outstanding_days_2'] = 'days ago';
 $txt['admin_browse_outstanding_perform'] = 'Perform the following action';
 $txt['admin_browse_outstanding_go'] = 'Perform Action';
 
-$txt['check_for_duplicate'] = 'Check for Duplicates';
-$txt['dont_check_for_duplicate'] = 'Don\'t Check for Duplicates';
+$txt['check_for_duplicate'] = 'Check for duplicates';
+$txt['dont_check_for_duplicate'] = 'Don\'t check for duplicates';
 $txt['duplicates'] = 'Duplicates';
 
 $txt['not_activated'] = 'Not activated';

+ 1 - 1
Themes/default/languages/ManageSettings.english.php

@@ -313,7 +313,7 @@ $txt['core_settings_item_pm_desc'] = 'Post moderation enables you to select grou
 $txt['core_settings_item_ps'] = 'Paid Subscriptions';
 $txt['core_settings_item_ps_desc'] = 'Paid subscriptions allow users to pay for subscriptions to change membergroup within the forum and thus change their access rights.';
 $txt['core_settings_item_rg'] = 'Report Generation';
-$txt['core_settings_item_rg_desc'] = 'This administration feature allows the generation of reports (Which can be printed) to present your current forum setup in an easy to view manner - particularly useful for large forums.';
+$txt['core_settings_item_rg_desc'] = 'This administration feature allows the generation of reports (which can be printed) to present your current forum setup in an easy to view manner - particularly useful for large forums.';
 $txt['core_settings_item_sp'] = 'Search Engine Tracking';
 $txt['core_settings_item_sp_desc'] = 'Enabling this feature will allow administrators to track search engines as they index your forum.';
 $txt['core_settings_item_w'] = 'Warning System';

+ 13 - 13
Themes/default/languages/ManageSmileys.english.php

@@ -20,12 +20,12 @@ $txt['smiley_sets_name'] = 'Name';
 $txt['smiley_sets_url'] = 'URL';
 $txt['smiley_sets_default'] = 'Default';
 
-$txt['smiley_sets_latest'] = 'Smileys of The Moment';
+$txt['smiley_sets_latest'] = 'Smileys of the moment';
 $txt['smiley_sets_latest_fetch'] = 'Loading smiley information from simplemachines.org...';
 
 $txt['smileys_add_method'] = 'Image Source';
-$txt['smileys_add_existing'] = 'Use Existing File';
-$txt['smileys_add_upload'] = 'Upload New Smiley';
+$txt['smileys_add_existing'] = 'Use existing file';
+$txt['smileys_add_upload'] = 'Upload new smiley';
 $txt['smileys_add_upload_choose'] = 'File to upload';
 $txt['smileys_add_upload_choose_desc'] = 'Image to be used by all smiley sets.';
 $txt['smileys_add_upload_all'] = 'Same image for all sets';
@@ -43,8 +43,8 @@ $txt['smileys_delete'] = 'Delete Smiley';
 $txt['smileys_delete_confirm'] = 'Are you sure you wish to delete this smiley?';
 $txt['smileys_with_selected'] = 'With Selected';
 $txt['smileys_make_hidden'] = 'Make Hidden';
-$txt['smileys_show_on_post'] = 'Show on Post Form';
-$txt['smileys_show_on_popup'] = 'Show on Popup';
+$txt['smileys_show_on_post'] = 'Show on post form';
+$txt['smileys_show_on_popup'] = 'Show on popup';
 
 $txt['smiley_settings_explain'] = 'These settings allow you to change the default smiley set, allow people to select their own smileys, and set paths and configuration data.';
 $txt['smiley_editsets_explain'] = 'Smiley Sets are groups of smileys your users can choose between.  For example, you might have yellow and red smileys.<br />Here you can change the name and location of each smiley set - remember, however, that all sets share the same smileys.';
@@ -52,9 +52,9 @@ $txt['smiley_editsmileys_explain'] = 'Change your smileys here by clicking on th
 $txt['smiley_setorder_explain'] = 'Change the order of the smileys here.';
 $txt['smiley_addsmiley_explain'] = 'Here you can add a new smiley - either from an existing file or by uploading new ones.';
 
-$txt['smiley_set_select_default'] = 'Default Smiley Set';
-$txt['smiley_set_new'] = 'Create new smiley set';
-$txt['smiley_set_modify_existing'] = 'Modify existing smiley set';
+$txt['smiley_set_select_default'] = 'Default Smiley set';
+$txt['smiley_set_new'] = 'Create new Smiley set';
+$txt['smiley_set_modify_existing'] = 'Modify existing Smiley set';
 $txt['smiley_set_modify'] = 'Modify';
 $txt['smiley_set_import_directory'] = 'Import smileys already in this directory';
 $txt['smiley_set_import_single'] = 'There is one smiley in this smiley set not yet imported. Click';
@@ -82,14 +82,14 @@ $txt['smileys_move_here'] = 'Move smiley to this location';
 $txt['smileys_no_entries'] = 'There are currently no smileys configured.';
 
 $txt['icons_edit_icons_explain'] = 'From here you can change which message icons are available throughout your board. You can add, edit and remove icons, as well as limit their use to certain boards.';
-$txt['icons_edit_icons_all_boards'] = 'Available In All Boards';
+$txt['icons_edit_icons_all_boards'] = 'Available in all boards';
 $txt['icons_board'] = 'Board';
 $txt['icons_confirm'] = 'Are you sure you wish to remove these icons?\\n\\nNote this will only stop new posters from using the icons, the images will remain.';
-$txt['icons_add_new'] = 'Add New Icon';
+$txt['icons_add_new'] = 'Add new icon';
 
-$txt['icons_edit_icon'] = 'Edit Message Icon';
-$txt['icons_new_icon'] = 'New Message Icon';
-$txt['icons_location_first_icon'] = 'As First Icon';
+$txt['icons_edit_icon'] = 'Edit message icon';
+$txt['icons_new_icon'] = 'New message icon';
+$txt['icons_location_first_icon'] = 'As first icon';
 $txt['icons_location_after'] = 'After';
 $txt['icons_filename_all_gif'] = 'All files must be &quot;gif&quot; files';
 $txt['icons_filename_all_png'] = 'All files must be &quot;png&quot; files';

+ 9 - 9
Themes/default/languages/ModerationCenter.english.php

@@ -55,11 +55,11 @@ $txt['mc_groupr_reason'] = 'Reason';
 $txt['mc_groupr_none_found'] = 'There are currently no outstanding membergroup requests.';
 $txt['mc_groupr_submit'] = 'Submit';
 $txt['mc_groupr_reason_desc'] = 'Reason to reject %1$s\'s request to join &quot;%2$s&quot;';
-$txt['mc_groups_reason_title'] = 'Reasons for Rejection';
-$txt['with_selected'] = 'With Selected';
-$txt['mc_groupr_approve'] = 'Approve Request';
-$txt['mc_groupr_reject'] = 'Reject Request (No Reason)';
-$txt['mc_groupr_reject_w_reason'] = 'Reject Request with Reason';
+$txt['mc_groups_reason_title'] = 'Reasons for rejection';
+$txt['with_selected'] = 'With selected';
+$txt['mc_groupr_approve'] = 'Approve request';
+$txt['mc_groupr_reject'] = 'Reject request (No Reason)';
+$txt['mc_groupr_reject_w_reason'] = 'Reject request with reason';
 // Do not use numeric entries in the below string.
 $txt['mc_groupr_warning'] = 'Are you sure you wish to do this?';
 
@@ -72,10 +72,10 @@ $txt['mc_unapproved_replies'] = 'Replies';
 $txt['mc_unapproved_topics'] = 'Topics';
 $txt['mc_unapproved_by'] = 'by';
 $txt['mc_unapproved_sure'] = 'Are you sure you want to do this?';
-$txt['mc_unapproved_attach_name'] = 'Attachment Name';
+$txt['mc_unapproved_attach_name'] = 'Attachment name';
 $txt['mc_unapproved_attach_size'] = 'Filesize';
 $txt['mc_unapproved_attach_poster'] = 'Poster';
-$txt['mc_viewmodreport'] = 'Moderation Report for %1$s by %2$s';
+$txt['mc_viewmodreport'] = 'Moderation report for %1$s by %2$s';
 $txt['mc_modreport_summary'] = 'There have been %1$d report(s) concerning this post.  The last report was %2$s.';
 $txt['mc_modreport_whoreported_title'] = 'Members who have reported this post';
 $txt['mc_modreport_whoreported_data'] = 'Reported by %1$s on %2$s.  They left the following message:';
@@ -104,8 +104,8 @@ $txt['mc_watched_users_member'] = 'Member';
 $txt['mc_warnings_description'] = 'From this section you can see which warnings have been issued to members of the forum. You can also add and modify the notification templates used when sending a warning to a member.';
 $txt['mc_warning_log'] = 'Log';
 $txt['mc_warning_templates'] = 'Custom Templates';
-$txt['mc_warning_log_title'] = 'Viewing Warning Log';
-$txt['mc_warning_templates_title'] = 'Custom Warning Templates';
+$txt['mc_warning_log_title'] = 'Viewing warning log';
+$txt['mc_warning_templates_title'] = 'Custom warning templates';
 
 $txt['mc_warnings_none'] = 'No warnings have been issued.';
 $txt['mc_warnings_recipient'] = 'Recipient';

+ 13 - 13
Themes/default/languages/Packages.english.php

@@ -38,13 +38,13 @@ $txt['package_manager_desc'] = 'From this easy to use interface, you can downloa
 $txt['installed_packages_desc'] = 'You can use the interface below to view those packages currently installed on the forum, and remove the ones you no longer require.';
 $txt['download_packages_desc'] = 'From this section you can choose to either download new packages from package servers, or upload a package file directly to the forum.';
 
-$txt['create_package'] = 'Create a New Package';
-$txt['download_new_package'] = 'Download New Packages';
-$txt['view_and_remove'] = 'View and Remove Installed Packages';
-$txt['modification_package'] = 'Modification Packages';
-$txt['avatar_package'] = 'Avatar Packages';
-$txt['language_package'] = 'Language Packages';
-$txt['unknown_package'] = 'Unknown Packages';
+$txt['create_package'] = 'Create a new Package';
+$txt['download_new_package'] = 'Download new packages';
+$txt['view_and_remove'] = 'View and remove installed packages';
+$txt['modification_package'] = 'Modification packages';
+$txt['avatar_package'] = 'Avatar packages';
+$txt['language_package'] = 'Language packages';
+$txt['unknown_package'] = 'Unknown packages';
 $txt['use_avatars'] = 'Use Avatars';
 $txt['add_languages'] = 'Add Language';
 $txt['list_files'] = 'List Files';
@@ -59,7 +59,7 @@ $txt['mod_name'] = 'Mod Name';
 $txt['mod_version'] = 'Version';
 $txt['mod_author'] = 'Author';
 $txt['author_website'] = 'Author\'s Homepage';
-$txt['package_no_description'] = 'No Description Given';
+$txt['package_no_description'] = 'No description given';
 $txt['package_description'] = 'Description';
 $txt['file_location'] = 'Location of file';
 
@@ -115,10 +115,10 @@ $txt['package_will_fail_popup'] = 'Are you sure you wish to continue installing
 $txt['package_will_fail_popup_uninstall'] = 'Are you sure you wish to continue uninstalling this modification, even though it will not uninstall successfully?';
 $txt['package_install'] = 'installation';
 $txt['package_uninstall'] = 'removal';
-$txt['package_install_now'] = 'Install Now';
-$txt['package_uninstall_now'] = 'Uninstall Now';
-$txt['package_other_themes'] = 'Install in Other Themes';
-$txt['package_other_themes_uninstall'] = 'UnInstall in Other Themes';
+$txt['package_install_now'] = 'Install now';
+$txt['package_uninstall_now'] = 'Uninstall now';
+$txt['package_other_themes'] = 'Install in other themes';
+$txt['package_other_themes_uninstall'] = 'UnInstall in other themes';
 $txt['package_other_themes_desc'] = 'To use this modification in themes other than the default, the package manager needs to make additional changes to the other themes. If you\'d like to install this modification in the other themes, please select these themes below.';
 // Don't use entities in the below string.
 $txt['package_theme_failure_warning'] = 'At least one error was encountered during a test install of this theme. Are you sure you wish to attempt installation?';
@@ -246,7 +246,7 @@ $txt['package_file_perms_files_done'] = '%1$d of %2$d files done in current dire
 
 $txt['chmod_value_invalid'] = 'You have tried to enter an invalid chmod value. Chmod must be between 0444 and 0777';
 
-$txt['package_restore_permissions'] = 'Restore File Permissions';
+$txt['package_restore_permissions'] = 'Restore file permissions';
 $txt['package_restore_permissions_desc'] = 'The following file permissions were changed by SMF to install the selected package(s). You can return these files back to their original status by clicking &quot;Restore&quot; below.';
 $txt['package_restore_permissions_restore'] = 'Restore';
 $txt['package_restore_permissions_filename'] = 'Filename';

+ 34 - 34
Themes/default/languages/PersonalMessage.english.php

@@ -50,27 +50,27 @@ $txt['pm_prune_desc2'] = 'days.';
 $txt['pm_prune_warning'] = 'Are you sure you wish to prune your personal messages?';
 
 // Actions Drop Down.
-$txt['pm_actions_title'] = 'Further Actions';
-$txt['pm_actions_delete_selected'] = 'Delete Selected';
-$txt['pm_actions_filter_by_label'] = 'Filter By Label';
+$txt['pm_actions_title'] = 'Further actions';
+$txt['pm_actions_delete_selected'] = 'Delete selected';
+$txt['pm_actions_filter_by_label'] = 'Filter by label';
 $txt['pm_actions_go'] = 'Go';
 
 // Manage Labels Screen.
 $txt['pm_apply'] = 'Apply';
-$txt['pm_manage_labels'] = 'Manage Labels';
+$txt['pm_manage_labels'] = 'Manage labels';
 $txt['pm_labels_delete'] = 'Are you sure you wish to delete the selected labels?';
 $txt['pm_labels_desc'] = 'From here you can add, edit and delete the labels used in your personal message center.';
-$txt['pm_label_add_new'] = 'Add New Label';
-$txt['pm_label_name'] = 'Label Name';
+$txt['pm_label_add_new'] = 'Add new label';
+$txt['pm_label_name'] = 'Label name';
 $txt['pm_labels_no_exist'] = 'You currently have no labels setup!';
 
 // Labeling Drop Down.
 $txt['pm_current_label'] = 'Label';
-$txt['pm_msg_label_title'] = 'Label Message';
-$txt['pm_msg_label_apply'] = 'Add Label';
-$txt['pm_msg_label_remove'] = 'Remove Label';
+$txt['pm_msg_label_title'] = 'Label message';
+$txt['pm_msg_label_apply'] = 'Add label';
+$txt['pm_msg_label_remove'] = 'Remove label';
 $txt['pm_msg_label_inbox'] = 'Inbox';
-$txt['pm_sel_label_title'] = 'Label Selected';
+$txt['pm_sel_label_title'] = 'Label selected';
 
 // Sidebar Headings.
 $txt['pm_labels'] = 'Labels';
@@ -81,8 +81,8 @@ $txt['pm_preferences'] = 'Preferences';
 $txt['pm_is_replied_to'] = 'You have forwarded or responded to this message.';
 
 // Reporting messages.
-$txt['pm_report_to_admin'] = 'Report To Admin';
-$txt['pm_report_title'] = 'Report Personal Message';
+$txt['pm_report_to_admin'] = 'Report to admin';
+$txt['pm_report_title'] = 'Report personal message';
 $txt['pm_report_desc'] = 'From this page you can report the personal message you received to the admin team of the forum. Please be sure to include a description of why you are reporting the message, as this will be sent along with the contents of the original message.';
 $txt['pm_report_admins'] = 'Administrator to send report to';
 $txt['pm_report_all_admins'] = 'Send to all forum administrators';
@@ -101,8 +101,8 @@ $txt['pm_report_pm_sent'] = 'Sent:';
 $txt['pm_report_done'] = 'Thank you for submitting this report. You should hear back from the admin team shortly.';
 $txt['pm_report_return'] = 'Return to the inbox';
 
-$txt['pm_search_title'] = 'Search Personal Messages';
-$txt['pm_search_bar_title'] = 'Search Messages';
+$txt['pm_search_title'] = 'Search personal messages';
+$txt['pm_search_bar_title'] = 'Search messages';
 $txt['pm_search_text'] = 'Search for';
 $txt['pm_search_go'] = 'Search';
 $txt['pm_search_advanced'] = 'Advanced search';
@@ -119,8 +119,8 @@ $txt['pm_search_between_days'] = 'days';
 $txt['pm_search_order'] = 'Search order';
 $txt['pm_search_choose_label'] = 'Choose labels to search by, or search all';
 
-$txt['pm_search_results'] = 'Search Results';
-$txt['pm_search_none_found'] = 'No Messages Found';
+$txt['pm_search_results'] = 'Search results';
+$txt['pm_search_none_found'] = 'No messages found';
 
 $txt['pm_search_orderby_relevant_first'] = 'Most relevant first';
 $txt['pm_search_orderby_recent_first'] = 'Most recent first';
@@ -129,20 +129,20 @@ $txt['pm_search_orderby_old_first'] = 'Oldest first';
 $txt['pm_visual_verification_label'] = 'Verification';
 $txt['pm_visual_verification_desc'] = 'Please enter the code in the image above to send this pm.';
 
-$txt['pm_settings'] = 'Change Settings';
-$txt['pm_change_view'] = 'Change View';
+$txt['pm_settings'] = 'Change settings';
+$txt['pm_change_view'] = 'Change view';
 
 $txt['pm_manage_rules'] = 'Manage Rules';
 $txt['pm_manage_rules_desc'] = 'Message rules allow you to automatically sort incoming messages dependant on a set of criteria you define. Below are all the rules you currently have setup. To edit a rule simply click the rule name.';
 $txt['pm_rules_none'] = 'You have not yet setup any message rules.';
 $txt['pm_rule_title'] = 'Rule';
-$txt['pm_add_rule'] = 'Add New Rule';
-$txt['pm_apply_rules'] = 'Apply Rules Now';
+$txt['pm_add_rule'] = 'Add new rule';
+$txt['pm_apply_rules'] = 'Apply rules now';
 // Use entities in the below string.
 $txt['pm_js_apply_rules_confirm'] = 'Are you sure you wish to apply the current rules to all personal messages?';
 $txt['pm_edit_rule'] = 'Edit Rule';
 $txt['pm_rule_save'] = 'Save Rule';
-$txt['pm_delete_selected_rule'] = 'Delete Selected Rules';
+$txt['pm_delete_selected_rule'] = 'Delete selected rules';
 // Use entities in the below string.
 $txt['pm_js_delete_rule_confirm'] = 'Are you sure you wish to delete the selected rules?';
 $txt['pm_rule_name'] = 'Name';
@@ -152,23 +152,23 @@ $txt['pm_rule_description'] = 'Description';
 $txt['pm_rule_not_defined'] = 'Add some criteria to begin building this rule description.';
 $txt['pm_rule_js_disabled'] = '<span class="alert"><strong>Note:</strong> You appear to have javascript disabled. We highly recommend you enable javascript to use this feature.</span>';
 $txt['pm_rule_criteria'] = 'Criteria';
-$txt['pm_rule_criteria_add'] = 'Add Criteria';
-$txt['pm_rule_criteria_pick'] = 'Choose Criteria';
-$txt['pm_rule_mid'] = 'Sender Name';
-$txt['pm_rule_gid'] = 'Sender\'s Group';
-$txt['pm_rule_sub'] = 'Message Subject Contains';
-$txt['pm_rule_msg'] = 'Message Body Contains';
-$txt['pm_rule_bud'] = 'Sender is Buddy';
-$txt['pm_rule_sel_group'] = 'Select Group';
-$txt['pm_rule_logic'] = 'When Checking Criteria';
+$txt['pm_rule_criteria_add'] = 'Add criteria';
+$txt['pm_rule_criteria_pick'] = 'Choose criteria';
+$txt['pm_rule_mid'] = 'Sender name';
+$txt['pm_rule_gid'] = 'Sender\'s group';
+$txt['pm_rule_sub'] = 'Message subject contains';
+$txt['pm_rule_msg'] = 'Message body contains';
+$txt['pm_rule_bud'] = 'Sender is buddy';
+$txt['pm_rule_sel_group'] = 'Select group';
+$txt['pm_rule_logic'] = 'When checking criteria';
 $txt['pm_rule_logic_and'] = 'All criteria must be met';
 $txt['pm_rule_logic_or'] = 'Any criteria can be met';
 $txt['pm_rule_actions'] = 'Actions';
-$txt['pm_rule_sel_action'] = 'Select an Action';
-$txt['pm_rule_add_action'] = 'Add Action';
+$txt['pm_rule_sel_action'] = 'Select an action';
+$txt['pm_rule_add_action'] = 'Add action';
 $txt['pm_rule_label'] = 'Label message with';
-$txt['pm_rule_sel_label'] = 'Select Label';
-$txt['pm_rule_delete'] = 'Delete Message';
+$txt['pm_rule_sel_label'] = 'Select label';
+$txt['pm_rule_delete'] = 'Delete message';
 $txt['pm_rule_no_name'] = 'You forgot to enter a name for the rule.';
 $txt['pm_rule_no_criteria'] = 'A rule must have at least one criteria and one action set.';
 $txt['pm_rule_too_complex'] = 'The rule you are creating is too long for SMF to store. Try breaking it up into smaller rules.';

+ 23 - 23
Themes/default/languages/Post.english.php

@@ -5,8 +5,8 @@ global $context;
 
 $txt['post_reply'] = 'Post reply';
 $txt['message_icon'] = 'Message icon';
-$txt['subject_not_filled'] = 'The Subject field was not filled out. It is required.';
-$txt['message_body_not_filled'] = 'The Message Body was not filled out. It is required.';
+$txt['subject_not_filled'] = 'The subject field was not filled out. It is required.';
+$txt['message_body_not_filled'] = 'The message body was not filled out. It is required.';
 // Use numeric entities in the below string.
 $txt['add_bbc'] = 'Add BBC tags';
 $txt['bold'] = 'Bold';
@@ -19,10 +19,10 @@ $txt['bbc_code'] = 'Insert Code';
 // Escape any single quotes in here twice.. 'it\'s' -> 'it\\\'s'.
 $txt['bbc_quote'] = 'Insert Quote';
 $txt['list'] = 'Insert List';
-$txt['list_unordered'] = 'Insert Unordered List';
-$txt['list_ordered'] = 'Insert Ordered List';
+$txt['list_unordered'] = 'Insert unordered list';
+$txt['list_ordered'] = 'Insert ordered list';
 
-$txt['change_color'] = 'Change Color';
+$txt['change_color'] = 'Change color';
 $txt['black'] = 'Black';
 $txt['red'] = 'Red';
 $txt['yellow'] = 'Yellow';
@@ -38,7 +38,7 @@ $txt['navy'] = 'Navy';
 $txt['maroon'] = 'Maroon';
 $txt['lime_green'] = 'Lime Green';
 $txt['white'] = 'White';
-$txt['disable_smileys'] = 'Disable Smileys';
+$txt['disable_smileys'] = 'Disable smileys';
 $txt['dont_use_smileys'] = 'Don\'t use smileys.';
 // Escape any single quotes in here twice.. 'it\'s' -> 'it\\\'s'.
 $txt['posted_on'] = 'Posted on';
@@ -49,30 +49,30 @@ $txt['excamation_point'] = 'Exclamation point';
 $txt['question_mark'] = 'Question mark';
 $txt['icon_poll'] = 'Poll';
 $txt['lamp'] = 'Lamp';
-$txt['add_smileys'] = 'Add Smileys';
+$txt['add_smileys'] = 'Add smileys';
 $txt['flash'] = 'Insert Flash';
 $txt['ftp'] = 'Insert FTP Link';
-$txt['image'] = 'Insert Image';
-$txt['table'] = 'Insert Table';
-$txt['table_td'] = 'Insert Table Column';
-$txt['topic_notify_no'] = 'There are no topics with Notification.';
+$txt['image'] = 'Insert image';
+$txt['table'] = 'Insert table';
+$txt['table_td'] = 'Insert table column';
+$txt['topic_notify_no'] = 'There are no topics with notification.';
 $txt['marquee'] = 'Marquee';
 $txt['teletype'] = 'Teletype';
 $txt['strike'] = 'Strikethrough';
 $txt['glow'] = 'Glow';
 $txt['shadow'] = 'Shadow';
-$txt['preformatted'] = 'Preformatted Text';
-$txt['left_align'] = 'Left Align';
-$txt['right_align'] = 'Right Align';
+$txt['preformatted'] = 'Preformatted text';
+$txt['left_align'] = 'Left align';
+$txt['right_align'] = 'Right align';
 $txt['superscript'] = 'Superscript';
 $txt['subscript'] = 'Subscript';
-$txt['table_tr'] = 'Insert Table Row';
+$txt['table_tr'] = 'Insert table row';
 $txt['post_too_long'] = 'Your message is too long. Please go back and shorten it, then try again.';
 $txt['horizontal_rule'] = 'Horizontal Rule';
-$txt['font_size'] = 'Font Size';
-$txt['font_face'] = 'Font Face';
-$txt['toggle_view'] = 'Toggle View';
-$txt['unformat_text'] = 'Remove Formatting';
+$txt['font_size'] = 'Font size';
+$txt['font_face'] = 'Font face';
+$txt['toggle_view'] = 'Toggle view';
+$txt['unformat_text'] = 'Remove formatting';
 
 $txt['rich_edit_wont_work'] = 'Your browser does not support Rich Text editing.';
 $txt['rich_edit_function_disabled'] = 'Your browser does not support this function.';
@@ -88,11 +88,11 @@ $txt['shortcuts_drafts'] = 'shortcuts: alt+s submit/post, alt+p preview or alt+d
 $txt['shortcuts_firefox'] = 'shortcuts: shift+alt+s submit/post or shift+alt+p preview';
 $txt['shortcuts_drafts_firefox'] = 'shortcuts: shift+alt+s submit/post, shift+alt+p preview or shift+alt+d save draft';
 $txt['option'] = 'Option';
-$txt['reset_votes'] = 'Reset Vote Count';
+$txt['reset_votes'] = 'Reset vote count';
 $txt['reset_votes_check'] = 'Check this if you want to reset all vote counts to 0.';
 $txt['votes'] = 'votes';
 $txt['attach'] = 'Attach';
-$txt['clean_attach'] = 'Clear Attachment';
+$txt['clean_attach'] = 'Clear attachment';
 $txt['attached'] = 'Attached';
 $txt['allowed_types'] = 'Allowed file types';
 $txt['cant_upload_type'] = 'You cannot upload that type of file. The only allowed extensions are %1$s.';
@@ -126,9 +126,9 @@ $txt['post_additionalopt'] = 'Other options';
 $txt['sticky_after'] = 'Sticky this topic.';
 $txt['move_after2'] = 'Move this topic.';
 $txt['back_to_topic'] = 'Return to this topic.';
-$txt['approve_this_post'] = 'Approve this Post';
+$txt['approve_this_post'] = 'Approve this post';
 
-$txt['retrieving_quote'] = 'Retrieving Quote...';
+$txt['retrieving_quote'] = 'Retrieving quote...';
 
 $txt['post_visual_verification_label'] = 'Verification';
 $txt['post_visual_verification_desc'] = 'Please enter the code in the image above to make this post.';

+ 1 - 0
Themes/default/languages/index.english.php

@@ -801,5 +801,6 @@ $txt['debug_show_queries'] = '[Show Queries]';
 $txt['debug_hide_queries'] = '[Hide Queries]';
 $txt['debug_tokens'] = 'Tokens: ';
 $txt['debug_browser'] = 'Browser ID: ';
+$txt['debug_hooks'] = 'Hooks called: ';
 
 ?>

+ 1 - 1
Themes/default/scripts/jquery.sceditor.js

@@ -3480,7 +3480,7 @@
 				if (popup_exists)
 				{
 					this.options.emoticons.more = this.options.emoticons.popup;
-					moreButton = $('<div class="sceditor-more-button" />').attr({class: "sceditor-more"}).text('[' + this._('More') + ']').click(function () {
+					moreButton = $('<div class="sceditor-more-button" />').attr({'class': "sceditor-more"}).text('[' + this._('More') + ']').click(function () {
 						if ($(".sceditor-smileyPopup").length > 0)
 						{
 							$(".sceditor-smileyPopup").fadeIn('fast');

+ 2 - 4
Themes/default/scripts/script.js

@@ -1196,11 +1196,9 @@ IconList.prototype.openPopup = function (oDiv, iMessageId)
 		this.oContainerDiv.style.display = 'none';
 		this.oContainerDiv.style.cursor = 'pointer';
 		this.oContainerDiv.style.position = 'absolute';
-		this.oContainerDiv.style.width = oDiv.offsetWidth + 'px';
 		this.oContainerDiv.style.background = this.opt.sContainerBackground;
 		this.oContainerDiv.style.border = this.opt.sContainerBorder;
-		this.oContainerDiv.style.padding = '1px';
-		this.oContainerDiv.style.textAlign = 'center';
+		this.oContainerDiv.style.padding = '6px 0px';
 		document.body.appendChild(this.oContainerDiv);
 
 		// Start to fetch its contents.
@@ -1230,7 +1228,7 @@ IconList.prototype.onIconsReceived = function (oXMLDoc)
 	var sItems = '';
 
 	for (var i = 0, n = icons.length; i < n; i++)
-		sItems += '<div onmouseover="' + this.opt.sBackReference + '.onItemHover(this, true)" onmouseout="' + this.opt.sBackReference + '.onItemHover(this, false);" onmousedown="' + this.opt.sBackReference + '.onItemMouseDown(this, \'' + icons[i].getAttribute('value') + '\');" style="padding: 3px 0px 3px 0px; margin-left: auto; margin-right: auto; border: ' + this.opt.sItemBorder + '; background: ' + this.opt.sItemBackground + '"><img src="' + icons[i].getAttribute('url') + '" alt="' + icons[i].getAttribute('name') + '" title="' + icons[i].firstChild.nodeValue + '" /></div>';
+		sItems += '<span onmouseover="' + this.opt.sBackReference + '.onItemHover(this, true)" onmouseout="' + this.opt.sBackReference + '.onItemHover(this, false);" onmousedown="' + this.opt.sBackReference + '.onItemMouseDown(this, \'' + icons[i].getAttribute('value') + '\');" style="padding: 2px 3px; line-height: 20px; border: ' + this.opt.sItemBorder + '; background: ' + this.opt.sItemBackground + '"><img src="' + icons[i].getAttribute('url') + '" alt="' + icons[i].getAttribute('name') + '" title="' + icons[i].firstChild.nodeValue + '" style="vertical-align: middle" /></span>';
 
 	setInnerHTML(this.oContainerDiv, sItems);
 	this.oContainerDiv.style.display = 'block';

+ 5 - 5
Themes/default/scripts/smf_jquery_plugins.js

@@ -137,18 +137,18 @@
 					$('body').append('<div id="' + oSettings.tooltipID + '" class="' + oSettings.tooltipClass + '"><div id="' + oSettings.tooltipTextID + '" style="display:none;"></div></div>');
 					
 					// load information in to our newly created div
-					var $tt = $('#' + oSettings.tooltipID);
-					var $ttContent = $('#' + oSettings.tooltipID + ' #' + oSettings.tooltipTextID);
+					var tt = $('#' + oSettings.tooltipID);
+					var ttContent = $('#' + oSettings.tooltipID + ' #' + oSettings.tooltipTextID);
 					
 					if (oSettings.tooltipContent == 'html')
-						$ttContent.html($(this).children('.' + oSettings.tooltipSwapClass).html());
+						ttContent.html($(this).children('.' + oSettings.tooltipSwapClass).html());
 					else
-						$ttContent.text($(this).children('.' + oSettings.tooltipSwapClass).text());
+						ttContent.text($(this).children('.' + oSettings.tooltipSwapClass).text());
 					
 					oSettings.tooltipContent
 					
 					// show then position or it may postion off screen
-					$tt.show();
+					tt.show();
 					showTooltip();
 					positionTooltip(event);
 				}

+ 158 - 83
Themes/default/scripts/topic.js

@@ -1,66 +1,134 @@
-var cur_topic_id, cur_msg_id, buff_subject, cur_subject_div, in_edit_mode = 0;
-var hide_prefixes = Array();
+// *** QuickModifyTopic object.
+function QuickModifyTopic(oOptions)
+{
+	this.opt = oOptions;
+	this.aHidePrefixes = this.opt.aHidePrefixes;
+	this.iCurTopicId = 0;
+	this.sCurMessageId = '';
+	this.sBuffSubject = '';
+	this.oCurSubjectDiv = null;
+	this.oTopicModHandle = document;
+	this.bInEditMode = false;
+	this.bMouseOnDiv = false;
+	this.bXmlHttpCapable = this.isXmlHttpCapable();
+	this.init();
+}
 
-function modify_topic(topic_id, first_msg_id)
+// @todo Determine if this is even needed anymore opera meh
+// Ajax supported?
+QuickModifyTopic.prototype.isXmlHttpCapable = function ()
 {
-	if (!('XMLHttpRequest' in window))
-		return;
+	if (typeof(window.XMLHttpRequest) == 'undefined')
+		return false;
 
+	// Opera didn't always support POST requests. So test it first.
 	if ('opera' in window)
 	{
 		var oTest = new XMLHttpRequest();
 		if (!('setRequestHeader' in oTest))
-			return;
+			return false;
 	}
 
+	return true;
+}
+
+// Used to initialise the object event handlers
+QuickModifyTopic.prototype.init = function ()
+{
+	// Attach some events to it so we can respond to actions
+	this.oTopicModHandle.instanceRef = this;
+
+	// detect and act on keypress
+	this.oTopicModHandle.onkeydown = function (oEvent) {return this.instanceRef.modify_topic_keypress(oEvent);};
+
+	// Used to detect when we've stopped editing.
+	this.oTopicModHandle.onclick = function (oEvent) {return this.instanceRef.modify_topic_click(oEvent);};
+}
+
+// called from the double click in the div
+QuickModifyTopic.prototype.modify_topic = function (topic_id, first_msg_id)
+{
 	// Add backwards compatibility with old themes.
 	if (typeof(cur_session_var) == 'undefined')
 		cur_session_var = 'sesc';
 
-	if (in_edit_mode == 1)
+	// already editing
+	if (this.bInEditMode)
 	{
-		if (cur_topic_id == topic_id)
+		// same message then just return, otherwise drop out of this edit.
+		if (this.iCurTopicId == topic_id)
 			return;
 		else
-			modify_topic_cancel();
+			this.modify_topic_cancel();
 	}
 
-	in_edit_mode = 1;
-	mouse_on_div = 1;
-	cur_topic_id = topic_id;
+	this.bInEditMode = true;
+	this.bMouseOnDiv = true;
+	this.iCurTopicId = topic_id;
 
-	if (typeof window.ajax_indicator == "function")
-		ajax_indicator(true);
-	getXMLDocument(smf_prepareScriptUrl(smf_scripturl) + "action=quotefast;quote=" + first_msg_id + ";modify;xml", onDocReceived_modify_topic);
+	// Get the topics current subject 
+	ajax_indicator(true);
+	sendXMLDocument.call(this, smf_prepareScriptUrl(smf_scripturl) + "action=quotefast;quote=" + first_msg_id + ";modify;xml", '', this.onDocReceived_modify_topic);
 }
 
-function onDocReceived_modify_topic(XMLDoc)
+// callback function from the modify_topic ajax call
+QuickModifyTopic.prototype.onDocReceived_modify_topic = function (XMLDoc)
 {
-	cur_msg_id = XMLDoc.getElementsByTagName("message")[0].getAttribute("id");
+	// If it is not valid then clean up
+	if (!XMLDoc || !XMLDoc.getElementsByTagName('message'))
+	{
+		this.modify_topic_cancel();
+		return true;
+	}
+	
+	this.sCurMessageId = XMLDoc.getElementsByTagName("message")[0].getAttribute("id");
+	this.oCurSubjectDiv = document.getElementById('msg_' + this.sCurMessageId.substr(4));
+	this.sBuffSubject = getInnerHTML(this.oCurSubjectDiv);
 
-	cur_subject_div = document.getElementById('msg_' + cur_msg_id.substr(4));
-	buff_subject = getInnerHTML(cur_subject_div);
+	// Here we hide any other things they want hidden on edit.
+	this.set_hidden_topic_areas('none');
 
-	// Here we hide any other things they want hiding on edit.
-	set_hidden_topic_areas('none');
+	// Show we are in edit mode and allow the edit
+	ajax_indicator(false);
+	this.modify_topic_show_edit(XMLDoc.getElementsByTagName("subject")[0].childNodes[0].nodeValue);
+}
 
-	modify_topic_show_edit(XMLDoc.getElementsByTagName("subject")[0].childNodes[0].nodeValue);
-	if (typeof window.ajax_indicator == "function")
-		ajax_indicator(false);
+// Cancel out of an edit and return things to back to what they were
+QuickModifyTopic.prototype.modify_topic_cancel = function ()
+{
+	setInnerHTML(this.oCurSubjectDiv, this.sBuffSubject);
+	this.set_hidden_topic_areas('');
+	this.bInEditMode = false;
+	
+	return false;
 }
 
-function modify_topic_cancel()
+// Simply restore/show any hidden bits during topic editing.
+QuickModifyTopic.prototype.set_hidden_topic_areas = function (set_style)
 {
-	setInnerHTML(cur_subject_div, buff_subject);
-	set_hidden_topic_areas('');
+	for (var i = 0; i < this.aHidePrefixes.length; i++)
+	{
+		if (document.getElementById(this.aHidePrefixes[i] + this.sCurMessageId.substr(4)) != null)
+			document.getElementById(this.aHidePrefixes[i] + this.sCurMessageId.substr(4)).style.display = set_style;
+	}
+}
 
-	in_edit_mode = 0;
-	return false;
+// For templating, shown that an inline edit is being made.
+QuickModifyTopic.prototype.modify_topic_show_edit = function (subject)
+{
+	// Just template the subject.
+	setInnerHTML(this.oCurSubjectDiv, '<input type="text" name="subject" value="' + subject + '" size="60" style="width: 95%;" maxlength="80" class="input_text" /><input type="hidden" name="topic" value="' + this.iCurTopicId + '" /><input type="hidden" name="msg" value="' + this.sCurMessageId.substr(4) + '" />');
+	
+	// attach mouse over and out events to this new div
+	this.oCurSubjectDiv.instanceRef = this;
+	this.oCurSubjectDiv.onmouseout = function (oEvent) {return this.instanceRef.modify_topic_mouseout(oEvent);};
+	this.oCurSubjectDiv.onmouseover = function (oEvent) {return this.instanceRef.modify_topic_mouseover(oEvent);};
 }
 
-function modify_topic_save(cur_session_id, cur_session_var)
+// Yup thats right, save it
+QuickModifyTopic.prototype.modify_topic_save = function (cur_session_id, cur_session_var)
 {
-	if (!in_edit_mode)
+	if (!this.bInEditMode)
 		return true;
 
 	// Add backwards compatibility with old themes.
@@ -72,18 +140,22 @@ function modify_topic_save(cur_session_id, cur_session_var)
 	x[x.length] = 'topic=' + parseInt(document.forms.quickModForm.elements['topic'].value);
 	x[x.length] = 'msg=' + parseInt(document.forms.quickModForm.elements['msg'].value);
 
-	if (typeof window.ajax_indicator == "function")
-		ajax_indicator(true);
-	sendXMLDocument(smf_prepareScriptUrl(smf_scripturl) + "action=jsmodify;topic=" + parseInt(document.forms.quickModForm.elements['topic'].value) + ";" + cur_session_var + "=" + cur_session_id + ";xml", x.join("&"), modify_topic_done);
+	// send in the call to save the updated topic subject
+	ajax_indicator(true);
+	sendXMLDocument.call(this, smf_prepareScriptUrl(smf_scripturl) + "action=jsmodify;topic=" + parseInt(document.forms.quickModForm.elements['topic'].value) + ";" + cur_session_var + "=" + cur_session_id + ";xml", x.join("&"), this.modify_topic_done);
 
 	return false;
 }
 
-function modify_topic_done(XMLDoc)
+// done with the edit, if all went well show the new topic title
+QuickModifyTopic.prototype.modify_topic_done = function (XMLDoc)
 {
-	if (!XMLDoc)
+	ajax_indicator(false);
+	
+	// If it is not valid then clean up
+	if (!XMLDoc || !XMLDoc.getElementsByTagName('subject'))
 	{
-		modify_topic_cancel();
+		this.modify_topic_cancel();
 		return true;
 	}
 
@@ -91,33 +163,68 @@ function modify_topic_done(XMLDoc)
 	var subject = message.getElementsByTagName("subject")[0];
 	var error = message.getElementsByTagName("error")[0];
 
-	if (typeof window.ajax_indicator == "function")
-		ajax_indicator(false);
+	// No subject or other error>
 
 	if (!subject || error)
 		return false;
 
-	subjectText = subject.childNodes[0].nodeValue;
-
-	modify_topic_hide_edit(subjectText);
-
-	set_hidden_topic_areas('');
-
-	in_edit_mode = 0;
+	this.modify_topic_hide_edit(subject.childNodes[0].nodeValue);
+	this.set_hidden_topic_areas('');
+	this.bInEditMode = false;
 
 	return false;
 }
 
-// Simply restore any hidden bits during topic editing.
-function set_hidden_topic_areas(set_style)
+// Done with the edit, put in new subject and link.
+QuickModifyTopic.prototype.modify_topic_hide_edit = function (subject)
+{
+	// Re-template the subject!
+	setInnerHTML(this.oCurSubjectDiv, '<a href="' + smf_scripturl + '?topic=' + this.iCurTopicId + '.0">' + subject + '<' +'/a>');
+}
+
+// keypress event ... like enter or escape
+QuickModifyTopic.prototype.modify_topic_keypress = function (oEvent)
 {
-	for (var i = 0; i < hide_prefixes.length; i++)
+	if (typeof(oEvent.keyCode) != "undefined")
 	{
-		if (document.getElementById(hide_prefixes[i] + cur_msg_id.substr(4)) != null)
-			document.getElementById(hide_prefixes[i] + cur_msg_id.substr(4)).style.display = set_style;
+		if (oEvent.keyCode == 27)
+		{
+			this.modify_topic_cancel();
+			if (typeof(oEvent.preventDefault) == "undefined")
+				oEvent.returnValue = false;
+			else
+				oEvent.preventDefault();
+		}
+		else if (oEvent.keyCode == 13)
+		{
+			this.modify_topic_save(smf_session_id, smf_session_var);
+			if (typeof(oEvent.preventDefault) == "undefined")
+				oEvent.returnValue = false;
+			else
+				oEvent.preventDefault();
+		}
 	}
 }
 
+// A click event to signal the finish of the edit 
+QuickModifyTopic.prototype.modify_topic_click = function (oEvent)
+{
+	if (this.bInEditMode && !this.bMouseOnDiv)
+		this.modify_topic_save(smf_session_id, smf_session_var);
+}
+
+// Moved out of the editing div
+QuickModifyTopic.prototype.modify_topic_mouseout = function (oEvent)
+{
+	this.bMouseOnDiv = false;
+}
+
+// Moved back over the editing div
+QuickModifyTopic.prototype.modify_topic_mouseover = function (oEvent)
+{
+	this.bMouseOnDiv = true;
+}
+
 // *** QuickReply object.
 function QuickReply(oOptions)
 {
@@ -628,38 +735,6 @@ function expandThumb(thumbID)
 	return false;
 }
 
-// For templating, shown when an inline edit is made.
-function modify_topic_show_edit(subject)
-{
-	// Just template the subject.
-	setInnerHTML(cur_subject_div, '<input type="text" name="subject" value="' + subject + '" size="60" style="width: 95%;" maxlength="80" onkeypress="modify_topic_keypress(event)" class="input_text" /><input type="hidden" name="topic" value="' + cur_topic_id + '" /><input type="hidden" name="msg" value="' + cur_msg_id.substr(4) + '" />');
-}
-
-function modify_topic_click()
-{
-	if (in_edit_mode == 1 && mouse_on_div == 0)
-		modify_topic_save(smf_sesion_id, smf_session_var);
-}
-
-function modify_topic_keypress(oEvent)
-{
-	if (typeof(oEvent.keyCode) != "undefined" && oEvent.keyCode == 13)
-	{
-		modify_topic_save(smf_sesion_id, smf_session_var);
-		if (typeof(oEvent.preventDefault) == "undefined")
-			oEvent.returnValue = false;
-		else
-			oEvent.preventDefault();
-	}
-}
-
-// And the reverse for hiding it.
-function modify_topic_hide_edit(subject)
-{
-	// Re-template the subject!
-	setInnerHTML(cur_subject_div, '<a href="' + smf_scripturl + '?topic=' + cur_topic_id + '.0">' + subject + '<' +'/a>');
-}
-
 function ignore_toggles(msgids, text)
 {
 	for (i = 0; i < msgids.length; i++)