Browse Source

! More housecleaning

Signed-off-by: Peter Spicer <[email protected]>
Peter Spicer 10 years ago
parent
commit
b6c4653df0
56 changed files with 237 additions and 249 deletions
  1. 8 10
      Sources/ManageAttachments.php
  2. 1 1
      Sources/ManageMaintenance.php
  3. 1 1
      Sources/ManagePaid.php
  4. 2 2
      Sources/Modlog.php
  5. 2 2
      Sources/PersonalMessage.php
  6. 2 2
      Sources/Post.php
  7. 1 1
      Sources/Profile.php
  8. 1 1
      Sources/Register.php
  9. 1 1
      Sources/Subs-Editor.php
  10. 1 1
      Sources/Subs-Members.php
  11. 3 3
      Sources/Who.php
  12. 6 6
      Themes/default/Admin.template.php
  13. 1 1
      Themes/default/BoardIndex.template.php
  14. 2 2
      Themes/default/Errors.template.php
  15. 1 1
      Themes/default/GenericControls.template.php
  16. 1 3
      Themes/default/GenericList.template.php
  17. 2 4
      Themes/default/GenericMenu.template.php
  18. 2 2
      Themes/default/Help.template.php
  19. 1 1
      Themes/default/Likes.template.php
  20. 6 6
      Themes/default/Login.template.php
  21. 1 1
      Themes/default/ManageAttachments.template.php
  22. 2 2
      Themes/default/ManageBans.template.php
  23. 5 5
      Themes/default/ManageBoards.template.php
  24. 1 1
      Themes/default/ManageCalendar.template.php
  25. 3 3
      Themes/default/ManageLanguages.template.php
  26. 1 1
      Themes/default/ManageMail.template.php
  27. 4 4
      Themes/default/ManageMaintenance.template.php
  28. 4 7
      Themes/default/ManageMembergroups.template.php
  29. 2 2
      Themes/default/ManageMembers.template.php
  30. 3 3
      Themes/default/ManageNews.template.php
  31. 3 3
      Themes/default/ManagePaid.template.php
  32. 7 7
      Themes/default/ManagePermissions.template.php
  33. 2 2
      Themes/default/ManageScheduledTasks.template.php
  34. 6 6
      Themes/default/ManageSearch.template.php
  35. 6 8
      Themes/default/ManageSmileys.template.php
  36. 2 2
      Themes/default/Memberlist.template.php
  37. 8 8
      Themes/default/ModerationCenter.template.php
  38. 1 1
      Themes/default/MoveTopic.template.php
  39. 2 2
      Themes/default/Notify.template.php
  40. 12 13
      Themes/default/Packages.template.php
  41. 12 12
      Themes/default/PersonalMessage.template.php
  42. 1 1
      Themes/default/Poll.template.php
  43. 4 4
      Themes/default/Post.template.php
  44. 21 21
      Themes/default/Profile.template.php
  45. 3 3
      Themes/default/Recent.template.php
  46. 9 9
      Themes/default/Register.template.php
  47. 4 4
      Themes/default/Reminder.template.php
  48. 4 4
      Themes/default/Reports.template.php
  49. 1 1
      Themes/default/Search.template.php
  50. 3 3
      Themes/default/SendTopic.template.php
  51. 2 2
      Themes/default/Settings.template.php
  52. 6 6
      Themes/default/SplitTopics.template.php
  53. 13 13
      Themes/default/Themes.template.php
  54. 1 1
      Themes/default/Who.template.php
  55. 26 26
      Themes/default/Wireless.template.php
  56. 7 7
      Themes/default/Xml.template.php

+ 8 - 10
Sources/ManageAttachments.php

@@ -30,7 +30,7 @@ if (!defined('SMF'))
  */
 function ManageAttachments()
 {
-	global $txt, $modSettings, $scripturl, $context, $options;
+	global $txt, $context;
 
 	// You have to be able to moderate the forum to do this.
 	isAllowedTo('manage_attachments');
@@ -87,7 +87,7 @@ function ManageAttachments()
 
 function ManageAttachmentSettings($return_config = false)
 {
-	global $txt, $modSettings, $scripturl, $context, $options, $sourcedir, $boarddir;
+	global $txt, $modSettings, $scripturl, $context, $sourcedir, $boarddir;
 
 	require_once($sourcedir . '/Subs-Attachments.php');
 
@@ -365,7 +365,7 @@ function ManageAvatarSettings($return_config = false)
  */
 function BrowseFiles()
 {
-	global $context, $txt, $scripturl, $options, $modSettings;
+	global $context, $txt, $scripturl, $modSettings;
 	global $smcFunc, $sourcedir, $settings;
 
 	// Attachments or avatars?
@@ -679,7 +679,7 @@ function list_getNumFiles($browse_type)
  */
 function MaintainFiles()
 {
-	global $context, $modSettings, $txt, $smcFunc;
+	global $context, $modSettings, $smcFunc;
 
 	$context['sub_template'] = 'maintenance';
 
@@ -829,7 +829,7 @@ function MoveAvatars()
  */
 function RemoveAttachmentByAge()
 {
-	global $modSettings, $smcFunc;
+	global $smcFunc;
 
 	checkSession('post', 'admin');
 
@@ -870,7 +870,7 @@ function RemoveAttachmentByAge()
  */
 function RemoveAttachmentBySize()
 {
-	global $modSettings, $smcFunc;
+	global $smcFunc;
 
 	checkSession('post', 'admin');
 
@@ -2527,7 +2527,7 @@ function list_getAttachDirs()
  */
 function list_getBaseDirs()
 {
-	global $modSettings, $context, $txt;
+	global $modSettings, $txt;
 
 	if (empty($modSettings['attachment_basedirectories']))
 		return;
@@ -2580,8 +2580,6 @@ function list_getBaseDirs()
  */
 function attachDirStatus($dir, $expected_files)
 {
-	global $sourcedir, $context;
-
 	if (!is_dir($dir))
 		return array('does_not_exist', true, '');
 	elseif (!is_writable($dir))
@@ -2615,7 +2613,7 @@ function attachDirStatus($dir, $expected_files)
  */
 function TransferAttachments()
 {
-	global $modSettings, $context, $smcFunc, $sourcedir, $txt, $boarddir;
+	global $modSettings, $smcFunc, $sourcedir, $txt, $boarddir;
 
 	checkSession();
 

+ 1 - 1
Sources/ManageMaintenance.php

@@ -22,7 +22,7 @@ if (!defined('SMF'))
  */
 function ManageMaintenance()
 {
-	global $txt, $modSettings, $scripturl, $context, $options;
+	global $txt, $modSettings, $scripturl, $context;
 
 	// You absolutely must be an admin by here!
 	isAllowedTo('admin_forum');

+ 1 - 1
Sources/ManagePaid.php

@@ -650,7 +650,7 @@ function ModifySubscription()
  */
 function ViewSubscribedUsers()
 {
-	global $context, $txt, $modSettings, $scripturl, $options, $smcFunc, $sourcedir;
+	global $context, $txt, $modSettings, $scripturl, $smcFunc, $sourcedir;
 
 	// Setup the template.
 	$context['page_title'] = $txt['viewing_users_subscribed'];

+ 2 - 2
Sources/Modlog.php

@@ -28,7 +28,7 @@ if (!defined('SMF'))
  */
 function ViewModlog()
 {
-	global $txt, $modSettings, $context, $scripturl, $sourcedir, $user_info, $smcFunc;
+	global $txt, $context, $scripturl, $sourcedir, $smcFunc;
 
 	// Are we looking at the moderation log or the administration log.
 	$context['log_type'] = isset($_REQUEST['sa']) && $_REQUEST['sa'] == 'adminlog' ? 3 : 1;
@@ -354,7 +354,7 @@ function list_getModLogEntryCount($query_string = '', $query_params = array(), $
  */
 function list_getModLogEntries($start, $items_per_page, $sort, $query_string = '', $query_params = array(), $log_type = 1)
 {
-	global $context, $scripturl, $txt, $smcFunc, $user_info;
+	global $scripturl, $txt, $smcFunc, $user_info;
 
 	$modlog_query = allowedTo('admin_forum') || $user_info['mod_cache']['bq'] == '1=1' ? '1=1' : ($user_info['mod_cache']['bq'] == '0=1' ? 'lm.id_board = 0 AND lm.id_topic = 0' : (strtr($user_info['mod_cache']['bq'], array('id_board' => 'b.id_board')) . ' AND ' . strtr($user_info['mod_cache']['bq'], array('id_board' => 't.id_board'))));
 

+ 2 - 2
Sources/PersonalMessage.php

@@ -230,7 +230,7 @@ function MessageMain()
  */
 function messageIndexBar($area)
 {
-	global $txt, $context, $scripturl, $sourcedir, $sc, $modSettings, $user_info, $options;
+	global $txt, $context, $scripturl, $sourcedir, $sc, $modSettings, $user_info;
 
 	$pm_areas = array(
 		'folders' => array(
@@ -1744,7 +1744,7 @@ function MessageSearch2()
 function MessagePost()
 {
 	global $txt, $sourcedir, $scripturl, $modSettings;
-	global $context, $options, $smcFunc, $language, $user_info;
+	global $context, $smcFunc, $language, $user_info;
 
 	isAllowedTo('pm_send');
 

+ 2 - 2
Sources/Post.php

@@ -33,7 +33,7 @@ function Post($post_errors = array())
 {
 	global $txt, $scripturl, $topic, $modSettings, $board;
 	global $user_info, $sc, $board_info, $context, $settings;
-	global $sourcedir, $options, $smcFunc, $language;
+	global $sourcedir, $smcFunc, $language;
 
 	loadLanguage('Post');
 
@@ -1165,7 +1165,7 @@ function Post($post_errors = array())
 function Post2()
 {
 	global $board, $topic, $txt, $modSettings, $sourcedir, $context;
-	global $user_info, $board_info, $options, $smcFunc;
+	global $user_info, $board_info, $smcFunc;
 
 	// Sneaking off, are we?
 	if (empty($_POST) && empty($topic))

+ 1 - 1
Sources/Profile.php

@@ -26,7 +26,7 @@ if (!defined('SMF'))
 function ModifyProfile($post_errors = array())
 {
 	global $txt, $scripturl, $user_info, $context, $sourcedir, $user_profile, $cur_profile;
-	global $modSettings, $memberContext, $profile_vars, $smcFunc, $post_errors, $options, $user_settings;
+	global $modSettings, $memberContext, $profile_vars, $post_errors, $user_settings;
 
 	// Don't reload this as we may have processed error strings.
 	if (empty($post_errors))

+ 1 - 1
Sources/Register.php

@@ -220,7 +220,7 @@ function Register($reg_errors = array())
 function Register2($verifiedOpenID = false)
 {
 	global $scripturl, $txt, $modSettings, $context, $sourcedir;
-	global $user_info, $options, $smcFunc;
+	global $user_info, $smcFunc;
 
 	checkSession();
 	validateToken('register');

+ 1 - 1
Sources/Subs-Editor.php

@@ -1937,7 +1937,7 @@ function create_control_richedit($editorOptions)
  */
 function create_control_verification(&$verificationOptions, $do_test = false)
 {
-	global $txt, $modSettings, $options, $smcFunc;
+	global $txt, $modSettings, $smcFunc;
 	global $context, $user_info, $sourcedir, $scripturl, $language;
 
 	// First verification means we need to set up some bits...

+ 1 - 1
Sources/Subs-Members.php

@@ -440,7 +440,7 @@ function deleteMembers($users, $check_not_admin = false)
 function registerMember(&$regOptions, $return_errors = false)
 {
 	global $scripturl, $txt, $modSettings, $context, $sourcedir;
-	global $user_info, $options, $smcFunc;
+	global $user_info, $smcFunc;
 
 	loadLanguage('Login');
 

+ 3 - 3
Sources/Who.php

@@ -29,7 +29,7 @@ if (!defined('SMF'))
  */
 function Who()
 {
-	global $context, $scripturl, $user_info, $txt, $modSettings, $memberContext, $smcFunc;
+	global $context, $scripturl, $txt, $modSettings, $memberContext, $smcFunc;
 
 	// Permissions, permissions, permissions.
 	isAllowedTo('who_view');
@@ -261,7 +261,7 @@ function Who()
  */
 function determineActions($urls, $preferred_prefix = false)
 {
-	global $txt, $user_info, $modSettings, $smcFunc, $context;
+	global $txt, $user_info, $modSettings, $smcFunc;
 
 	if (!allowedTo('who_view'))
 		return array();
@@ -520,7 +520,7 @@ function determineActions($urls, $preferred_prefix = false)
  */
 function Credits($in_admin = false)
 {
-	global $context, $smcFunc, $modSettings, $forum_copyright, $forum_version, $software_year, $boardurl, $txt, $user_info;
+	global $context, $smcFunc, $forum_copyright, $forum_version, $software_year, $txt, $user_info;
 
 	// Don't blink. Don't even blink. Blink and you're dead.
 	loadLanguage('Who');

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

@@ -15,7 +15,7 @@
  */
 function template_admin()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	// Welcome message for the admin.
 	echo '
@@ -161,7 +161,7 @@ function template_admin()
  */
 function template_credits()
 {
-	global $context, $settings, $options, $scripturl, $txt;
+	global $context, $settings, $scripturl, $txt;
 
 	// Show the user version information from their server.
 	echo '
@@ -306,7 +306,7 @@ function template_credits()
  */
 function template_view_versions()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 					<div id="admincenter">
@@ -534,7 +534,7 @@ function template_view_versions()
 // Form for stopping people using naughty words, etc.
 function template_edit_censored()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	if (!empty($context['saved_successful']))
 		echo '
@@ -622,7 +622,7 @@ function template_edit_censored()
 // Maintenance is a lovely thing, isn't it?
 function template_not_done()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 					<div id="admincenter">
@@ -1222,7 +1222,7 @@ function template_edit_profile_field()
 // Results page for an admin search.
 function template_admin_search_results()
 {
-	global $context, $txt, $settings, $options, $scripturl;
+	global $context, $txt, $settings, $scripturl;
 
 	echo '
 						<div id="section_header" class="cat_bar">

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

@@ -79,7 +79,7 @@ function template_newsfader()
 
 function template_main()
 {
-	global $context, $settings, $options, $txt, $scripturl, $modSettings;
+	global $context, $settings, $txt, $scripturl, $modSettings;
 
 	echo '
 	<div id="boardindex_table" class="boardindex_table">

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

@@ -19,7 +19,7 @@
 // Show an error message.....
 function template_fatal_error()
 {
-	global $context, $options, $txt;
+	global $context, $txt;
 
 	echo '
 	<div id="fatal_error">
@@ -43,7 +43,7 @@ function template_fatal_error()
 
 function template_error_log()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	echo '
 		<form class="generic_list_wrapper" action="', $scripturl, '?action=admin;area=logs;sa=errorlog', $context['sort_direction'] == 'down' ? ';desc' : '', ';start=', $context['start'], $context['has_filter'] ? $context['filter']['href'] : '', '" method="post" accept-charset="', $context['character_set'], '">';

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

@@ -216,7 +216,7 @@ function template_control_richedit_buttons($editor_id)
 // What's this, verification?!
 function template_control_verification($verify_id, $display_type = 'all', $reset = false)
 {
-	global $context, $options, $txt, $modSettings;
+	global $context, $txt, $modSettings;
 
 	$verify_context = &$context['controls']['verification'][$verify_id];
 

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

@@ -12,7 +12,7 @@
 
 function template_show_list($list_id = null)
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	// Get a shortcut to the current list.
 	$list_id = $list_id === null ? $context['default_list'] : $list_id;
@@ -185,8 +185,6 @@ function template_show_list($list_id = null)
 
 function template_additional_rows($row_position, $cur_list)
 {
-	global $context, $options;
-
 	foreach ($cur_list['additional_rows'][$row_position] as $row)
 		echo '
 			<div class="additional_row', empty($row['class']) ? '' : ' ' . $row['class'], '"', empty($row['style']) ? '' : ' style="' . $row['style'] . '"', '>', $row['value'], '</div>';

+ 2 - 4
Themes/default/GenericMenu.template.php

@@ -13,7 +13,7 @@
 // This contains the html for the side bar of the admin center, which is used for all admin pages.
 function template_generic_menu_dropdown_above()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	// Which menu are we rendering?
 	$context['cur_menu_id'] = isset($context['cur_menu_id']) ? $context['cur_menu_id'] + 1 : 1;
@@ -97,8 +97,6 @@ function template_generic_menu_dropdown_above()
 // Part of the admin layer - used with admin_above to close the table started in it.
 function template_generic_menu_dropdown_below()
 {
-	global $context, $options;
-
 	echo '
 				</div>';
 }
@@ -106,7 +104,7 @@ function template_generic_menu_dropdown_below()
 // Some code for showing a tabbed view.
 function template_generic_menu_tabs(&$menu_context)
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	// Handy shortcut.
 	$tab_context = &$menu_context['tab_data'];

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

@@ -12,7 +12,7 @@
 
 function template_popup()
 {
-	global $context, $settings, $options, $txt;
+	global $context, $settings, $txt;
 
 	// Since this is a popup of its own we need to start the html, etc.
 	echo '<!DOCTYPE html>
@@ -36,7 +36,7 @@ function template_popup()
 
 function template_find_members()
 {
-	global $context, $settings, $options, $scripturl, $modSettings, $txt;
+	global $context, $settings, $scripturl, $modSettings, $txt;
 
 	echo '<!DOCTYPE html>
 <html', $context['right_to_left'] ? ' dir="rtl"' : '', '>

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

@@ -12,7 +12,7 @@
 
 function template_popup()
 {
-	global $context, $settings, $options, $txt;
+	global $context, $settings, $txt;
 
 	// Since this is a popup of its own we need to start the html, etc.
 	echo '<!DOCTYPE html>

+ 6 - 6
Themes/default/Login.template.php

@@ -13,7 +13,7 @@
 // This is just the basic "login" form.
 function template_login()
 {
-	global $context, $settings, $options, $scripturl, $modSettings, $txt;
+	global $context, $settings, $scripturl, $modSettings, $txt;
 
 	echo '
 		<script src="', $settings['default_theme_url'], '/scripts/sha1.js"></script>
@@ -86,7 +86,7 @@ function template_login()
 // Tell a guest to get lost or login!
 function template_kick_guest()
 {
-	global $context, $settings, $options, $scripturl, $modSettings, $txt;
+	global $context, $settings, $scripturl, $modSettings, $txt;
 
 	// This isn't that much... just like normal login but with a message at the top.
 	echo '
@@ -158,7 +158,7 @@ function template_kick_guest()
 // This is for maintenance mode.
 function template_maintenance()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	// Display the administrator's message at the top.
 	echo '
@@ -199,7 +199,7 @@ function template_maintenance()
 // This is for the security stuff - makes administrators login every so often.
 function template_admin_login()
 {
-	global $context, $settings, $options, $scripturl, $txt;
+	global $context, $settings, $scripturl, $txt;
 
 	// Since this should redirect to whatever they were doing, send all the get data.
 	echo '
@@ -243,7 +243,7 @@ function template_admin_login()
 // Activate your account manually?
 function template_retry_activate()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	// Just ask them for their code so they can try it again...
 	echo '
@@ -272,7 +272,7 @@ function template_retry_activate()
 // Activate your account manually?
 function template_resend()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	// Just ask them for their code so they can try it again...
 	echo '

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

@@ -35,7 +35,7 @@ function template_avatar_settings_below()
 
 function template_maintenance()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="manage_attachments">

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

@@ -12,7 +12,7 @@
 
 function template_ban_edit()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="manage_bans">
@@ -238,7 +238,7 @@ function template_ban_edit()
 
 function template_ban_edit_trigger()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="manage_bans">

+ 5 - 5
Themes/default/ManageBoards.template.php

@@ -13,7 +13,7 @@
 // Template for listing all the current categories and boards.
 function template_main()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	// Table header.
 	echo '
@@ -110,7 +110,7 @@ function template_main()
 // Template for editing/adding a category on the forum.
 function template_modify_category()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	// Print table header.
 	echo '
@@ -199,7 +199,7 @@ function template_modify_category()
 // A template to confirm if a user wishes to delete a category - and whether they want to save the boards.
 function template_confirm_category_delete()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	// Print table header.
 	echo '
@@ -253,7 +253,7 @@ function template_confirm_category_delete()
 // Below is the template for adding/editing an board on the forum.
 function template_modify_board()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	// The main table header.
 	echo '
@@ -660,7 +660,7 @@ function template_modify_board()
 // A template used when a user is deleting a board with child boards in it - to see what they want to do with them.
 function template_confirm_board_delete()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	// Print table header.
 	echo '

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

@@ -13,7 +13,7 @@
 // Editing or adding holidays.
 function template_edit_holiday()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	// Start with javascript for getting the calendar dates right.
 	echo '

+ 3 - 3
Themes/default/ManageLanguages.template.php

@@ -16,7 +16,7 @@
  */
 function template_download_language()
 {
-	global $context, $settings, $options, $txt, $scripturl, $modSettings;
+	global $context, $settings, $txt, $scripturl, $modSettings;
 
 	// Actually finished?
 	if (!empty($context['install_complete']))
@@ -234,7 +234,7 @@ function template_download_language()
  */
 function template_modify_language_entries()
 {
-	global $context, $settings, $options, $txt, $scripturl;
+	global $context, $settings, $txt, $scripturl;
 
 	echo '
 	<div id="admincenter">
@@ -429,7 +429,7 @@ function template_modify_language_entries()
  */
 function template_add_language()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="admincenter">

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

@@ -12,7 +12,7 @@
 
 function template_browse()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<div id="manage_mail">

+ 4 - 4
Themes/default/ManageMaintenance.template.php

@@ -13,7 +13,7 @@
 // Template for the database maintenance tasks.
 function template_maintain_database()
 {
-	global $context, $options, $txt, $scripturl, $db_type, $modSettings;
+	global $context, $txt, $scripturl, $db_type, $modSettings;
 
 	// If maintenance has finished tell the user.
 	if (!empty($context['maintenance_finished']))
@@ -104,7 +104,7 @@ function template_maintain_database()
 // Template for the routine maintenance tasks.
 function template_maintain_routine()
 {
-	global $context, $options, $txt, $scripturl, $modSettings;
+	global $context, $txt, $scripturl, $modSettings;
 
 	// Starts off with general maintenance procedures.
 	echo '
@@ -193,7 +193,7 @@ function template_maintain_routine()
 // Template for the member maintenance tasks.
 function template_maintain_members()
 {
-	global $context, $settings, $options, $txt, $scripturl;
+	global $context, $settings, $txt, $scripturl;
 
 	echo '
 	<script><!-- // --><![CDATA[
@@ -537,7 +537,7 @@ function template_maintain_topics()
 // Simple template for showing results of our optimization...
 function template_optimize()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="manage_maintenance">

+ 4 - 7
Themes/default/ManageMembergroups.template.php

@@ -12,17 +12,14 @@
 
 function template_main()
 {
-	global $context, $options, $scripturl, $txt;
-
 	template_show_list('regular_membergroups_list');
 	echo '<br /><br />';
 	template_show_list('post_count_membergroups_list');
-
 }
 
 function template_new_group()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">
@@ -151,7 +148,7 @@ function template_new_group()
 
 function template_edit_group()
 {
-	global $context, $settings, $options, $scripturl, $txt;
+	global $context, $settings, $scripturl, $txt;
 
 	echo '
 	<div id="admincenter">
@@ -503,7 +500,7 @@ function template_add_edit_group_boards_list($collapse = true)
 // Templating for viewing the members of a group.
 function template_group_members()
 {
-	global $context, $settings, $options, $scripturl, $txt;
+	global $context, $settings, $scripturl, $txt;
 
 	echo '
 	<div id="admincenter">
@@ -701,7 +698,7 @@ function template_group_members()
 // Allow the moderator to enter a reason to each user being rejected.
 function template_group_request_reason()
 {
-	global $options, $context, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	// Show a welcome message to the user.
 	echo '

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

@@ -12,7 +12,7 @@
 
 function template_search_members()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<div id="admincenter">
@@ -239,7 +239,7 @@ function template_search_members()
 
 function template_admin_browse()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">';

+ 3 - 3
Themes/default/ManageNews.template.php

@@ -12,7 +12,7 @@
 
 function template_email_members()
 {
-	global $context, $settings, $options, $txt, $scripturl;
+	global $context, $settings, $txt, $scripturl;
 
 	echo '
 	<div id="admincenter">
@@ -178,7 +178,7 @@ function template_email_members()
 
 function template_email_members_compose()
 {
-	global $context, $settings, $options, $txt, $scripturl;
+	global $context, $settings, $txt, $scripturl;
 
 	echo '
 		<div id="preview_section"', isset($context['preview_message']) ? '' : ' style="display: none;"', '>
@@ -388,7 +388,7 @@ function template_email_members_compose()
 
 function template_email_members_send()
 {
-	global $context, $settings, $options, $txt, $scripturl;
+	global $context, $settings, $txt, $scripturl;
 
 	echo '
 	<div id="admincenter">

+ 3 - 3
Themes/default/ManagePaid.template.php

@@ -13,7 +13,7 @@
 // The template for adding or editing a subscription.
 function template_modify_subscription()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">
@@ -197,7 +197,7 @@ function template_modify_subscription()
 
 function template_delete_subscription()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">
@@ -222,7 +222,7 @@ function template_delete_subscription()
 // Add or edit an existing subscriber.
 function template_modify_user_subscription()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	// Some quickly stolen javascript from Post, could do with being more efficient :)
 	echo '

+ 7 - 7
Themes/default/ManagePermissions.template.php

@@ -13,7 +13,7 @@
 
 function template_permission_index()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	// Not allowed to edit?
 	if (!$context['can_modify'])
@@ -266,7 +266,7 @@ function template_permission_index()
 
 function template_by_board()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">
@@ -362,7 +362,7 @@ function template_by_board()
 // Edit permission profiles (predefined).
 function template_edit_profiles()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admin_form_wrapper">
@@ -461,7 +461,7 @@ function template_edit_profiles()
 
 function template_modify_group()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	// Cannot be edited?
 	if (!$context['profile']['can_modify'])
@@ -550,7 +550,7 @@ function template_modify_group()
 // The way of looking at permissions.
 function template_modify_group_display($type)
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	$permission_type = &$context['permissions'][$type];
 	$disable_field = $context['profile']['can_modify'] ? '' : 'disabled="disabled" ';
@@ -711,7 +711,7 @@ function template_modify_group_display($type)
 
 function template_inline_permissions()
 {
-	global $context, $options, $txt, $modSettings;
+	global $context, $txt, $modSettings;
 
 	// This looks really weird, but it keeps things nested properly...
 	echo '
@@ -782,7 +782,7 @@ function template_inline_permissions()
 // Edit post moderation permissions.
 function template_postmod_permissions()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	echo '
 					<div id="admin_form_wrapper">

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

@@ -13,7 +13,7 @@
 // Template for listing all scheduled tasks.
 function template_view_scheduled_tasks()
 {
-	global $context, $options, $txt, $scripturl, $modSettings;
+	global $context, $txt, $scripturl, $modSettings;
 
 	// We completed some tasks?
 	if (!empty($context['tasks_were_run']))
@@ -53,7 +53,7 @@ function template_view_scheduled_tasks()
 // A template for, you guessed it, editing a task!
 function template_edit_scheduled_tasks()
 {
-	global $context, $options, $txt, $scripturl, $modSettings;
+	global $context, $txt, $scripturl, $modSettings;
 
 	// Starts off with general maintenance procedures.
 	echo '

+ 6 - 6
Themes/default/ManageSearch.template.php

@@ -12,7 +12,7 @@
 
 function template_modify_weights()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">
@@ -90,7 +90,7 @@ function template_modify_weights()
 
 function template_select_search_method()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">
@@ -219,7 +219,7 @@ function template_select_search_method()
 
 function template_create_index()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<div id="admincenter">
@@ -252,7 +252,7 @@ function template_create_index()
 
 function template_create_index_progress()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 	echo '
 	<div id="admincenter">
 		<form action="', $scripturl, '?action=admin;area=managesearch;sa=createmsgindex;step=1" name="autoSubmit" method="post" accept-charset="', $context['character_set'], '">
@@ -300,7 +300,7 @@ function template_create_index_progress()
 
 function template_create_index_done()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 	echo '
 	<div id="admincenter">
 		<div class="cat_bar">
@@ -320,7 +320,7 @@ function template_create_index_done()
 // Add or edit a search engine spider.
 function template_spider_edit()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 	echo '
 	<div id="admincenter">
 		<form id="admin_form_wrapper" action="', $scripturl, '?action=admin;area=sengines;sa=editspiders;sid=', $context['spider']['id'], '" method="post" accept-charset="', $context['character_set'], '">

+ 6 - 8
Themes/default/ManageSmileys.template.php

@@ -13,7 +13,7 @@
 // Editing the smiley sets.
 function template_editsets()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">';
@@ -69,7 +69,7 @@ function template_editsets()
 // Modifying a smiley set.
 function template_modifyset()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">
@@ -155,7 +155,7 @@ function template_modifyset()
 // Editing an individual smiley
 function template_modifysmiley()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">
@@ -248,7 +248,7 @@ function template_modifysmiley()
 // Adding a new smiley.
 function template_addsmiley()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">
@@ -384,7 +384,7 @@ function template_addsmiley()
 // Ordering smileys.
 function template_setorder()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">';
@@ -436,15 +436,13 @@ function template_setorder()
 // Editing Message Icons
 function template_editicons()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
-
 	template_show_list('message_icon_list');
 }
 
 // Editing an individual message icon
 function template_editicon()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">

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

@@ -13,7 +13,7 @@
 // Displays a sortable listing of all members registered on the forum.
 function template_main()
 {
-	global $context, $settings, $options, $scripturl, $txt;
+	global $context, $settings, $scripturl, $txt;
 
 	echo '
 	<div class="main_section" id="memberlist">
@@ -157,7 +157,7 @@ function template_main()
 // A page allowing people to search the member list.
 function template_search()
 {
-	global $context, $settings, $options, $scripturl, $txt;
+	global $context, $settings, $scripturl, $txt;
 
 	// Start the submission form for the search!
 	echo '

+ 8 - 8
Themes/default/ModerationCenter.template.php

@@ -12,7 +12,7 @@
 
 function template_moderation_center()
 {
-	global $settings, $options, $context, $txt, $scripturl;
+	global $settings, $context, $txt, $scripturl;
 
 	// Show moderators notes.
 	template_notes();
@@ -45,7 +45,7 @@ function template_moderation_center()
 // Show all the group requests the user can see.
 function template_group_requests_block()
 {
-	global $options, $context, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 		<div class="cat_bar">
@@ -178,7 +178,7 @@ function template_reported_posts_block()
 
 function template_watched_users()
 {
-	global $options, $context, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 		<div class="cat_bar">
@@ -245,7 +245,7 @@ function template_watched_users()
 // Little section for making... notes.
 function template_notes()
 {
-	global $settings, $options, $context, $txt, $scripturl;
+	global $settings, $context, $txt, $scripturl;
 
 	echo '
 		<div class="modnotes">
@@ -287,7 +287,7 @@ function template_notes()
 
 function template_reported_posts()
 {
-	global $options, $context, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	// Let them know the action was a success.
 	if (!empty($context['report_post_action']) && !empty($txt['report_action_'. $context['report_post_action']]))
@@ -595,7 +595,7 @@ function template_user_watch_post_callback($post)
 // Moderation settings
 function template_moderation_settings()
 {
-	global $options, $context, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="modcenter">
@@ -631,7 +631,7 @@ function template_moderation_settings()
 // Show a notice sent to a user.
 function template_show_notice()
 {
-	global $txt, $settings, $options, $context;
+	global $txt, $settings, $context;
 
 	// We do all the HTML for this one!
 	echo '<!DOCTYPE html>
@@ -668,7 +668,7 @@ function template_show_notice()
 // Add or edit a warning template.
 function template_warn_template()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="modcenter">

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

@@ -15,7 +15,7 @@
  */
 function template_main()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="move_topic" class="lower_padding">

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

@@ -12,7 +12,7 @@
 
 function template_main()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 		<div class="cat_bar">
@@ -30,7 +30,7 @@ function template_main()
 
 function template_notify_board()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 		<div class="cat_bar">

+ 12 - 13
Themes/default/Packages.template.php

@@ -12,12 +12,11 @@
 
 function template_main()
 {
-	global $context, $options;
 }
 
 function template_view_package()
 {
-	global $context, $settings, $options, $txt, $scripturl, $smcFunc;
+	global $context, $settings, $txt, $scripturl, $smcFunc;
 
 	echo '
 	<div id="admincenter">
@@ -394,7 +393,7 @@ function template_view_package()
 
 function template_extract_package()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	if (!empty($context['redirect_url']))
 	{
@@ -473,7 +472,7 @@ function template_extract_package()
 
 function template_list()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="admincenter">
@@ -502,7 +501,7 @@ function template_list()
 
 function template_examine()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="admincenter">
@@ -523,7 +522,7 @@ function template_examine()
 
 function template_browse()
 {
-	global $context, $settings, $options, $txt, $scripturl, $modSettings, $forum_version;
+	global $context, $settings, $txt, $scripturl, $modSettings, $forum_version;
 
 	echo '
 	<div id="admincenter">';
@@ -680,7 +679,7 @@ function template_browse()
 
 function template_servers()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	if (!empty($context['package_ftp']['error']))
 			echo '
@@ -831,7 +830,7 @@ function template_servers()
 
 function template_package_confirm()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="admincenter">
@@ -849,7 +848,7 @@ function template_package_confirm()
 
 function template_package_list()
 {
-	global $context, $options, $txt, $scripturl, $smcFunc;
+	global $context, $txt, $scripturl, $smcFunc;
 
 	echo '
 	<div id="admincenter">
@@ -1023,7 +1022,7 @@ function template_package_list()
 
 function template_downloaded()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="admincenter">
@@ -1048,7 +1047,7 @@ function template_downloaded()
 
 function template_install_options()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	if (!empty($context['saved_successful']))
 		echo '
@@ -1109,7 +1108,7 @@ function template_install_options()
 
 function template_control_chmod()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	// Nothing to do? Brilliant!
 	if (empty($context['package_ftp']))
@@ -1257,7 +1256,7 @@ function template_control_chmod()
 
 function template_ftp_required()
 {
-	global $context, $options, $txt, $scripturl;
+	global $txt;
 
 	echo '
 		<fieldset>

+ 12 - 12
Themes/default/PersonalMessage.template.php

@@ -14,7 +14,7 @@
 // This is for stuff above the menu in the personal messages section.
 function template_pm_above()
 {
-	global $context, $options, $txt;
+	global $context, $txt;
 
 	echo '
 	<div id="personal_messages">';
@@ -588,7 +588,7 @@ function template_folder()
 // Just list all the personal message subjects - to make templates easier.
 function template_subject_list()
 {
-	global $context, $options, $settings, $modSettings, $txt, $scripturl;
+	global $context, $settings, $modSettings, $txt, $scripturl;
 
 	echo '
 	<table class="table_grid">
@@ -703,7 +703,7 @@ function template_subject_list()
 
 function template_search()
 {
-	global $context, $options, $scripturl, $modSettings, $txt;
+	global $context, $scripturl, $modSettings, $txt;
 
 	echo '
 	<form action="', $scripturl, '?action=pm;sa=search2" method="post" accept-charset="', $context['character_set'], '" name="searchform" id="searchform">
@@ -847,7 +847,7 @@ function template_search()
 
 function template_search_results()
 {
-	global $context, $options, $scripturl, $modSettings, $txt;
+	global $context, $scripturl, $modSettings, $txt;
 
 	echo '
 		<div class="cat_bar">
@@ -1351,7 +1351,7 @@ function template_send()
 // This template asks the user whether they wish to empty out their folder/messages.
 function template_ask_delete()
 {
-	global $context, $options, $scripturl, $modSettings, $txt;
+	global $context, $scripturl, $modSettings, $txt;
 
 	echo '
 		<div class="cat_bar">
@@ -1368,7 +1368,7 @@ function template_ask_delete()
 // This template asks the user what messages they want to prune.
 function template_prune()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<form action="', $scripturl, '?action=pm;sa=prune" method="post" accept-charset="', $context['character_set'], '" onsubmit="return confirm(\'', $txt['pm_prune_warning'], '\');">
@@ -1388,7 +1388,7 @@ function template_prune()
 // Here we allow the user to setup labels, remove labels and change rules for labels (i.e, do quite a bit)
 function template_labels()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<form action="', $scripturl, '?action=pm;sa=manlabels" method="post" accept-charset="', $context['character_set'], '">
@@ -1478,7 +1478,7 @@ function template_labels()
 // Template for reporting a personal message.
 function template_report_message()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<form action="', $scripturl, '?action=pm;sa=report;l=', $context['current_label_id'], '" method="post" accept-charset="', $context['character_set'], '">
@@ -1532,7 +1532,7 @@ function template_report_message()
 // Little template just to say "Yep, it's been submitted"
 function template_report_message_complete()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 		<div class="cat_bar">
@@ -1549,7 +1549,7 @@ function template_report_message_complete()
 // Manage rules.
 function template_rules()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<form action="', $scripturl, '?action=pm;sa=manrules" method="post" accept-charset="', $context['character_set'], '" name="manRules" id="manrules">
@@ -1624,7 +1624,7 @@ function template_rules()
 // Template for adding/editing a rule.
 function template_add_rule()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<script><!-- // --><![CDATA[
@@ -1925,7 +1925,7 @@ function template_add_rule()
 // Template for showing all the PM drafts of the user.
 function template_showPMDrafts()
 {
-	global $context, $options, $scripturl, $modSettings, $txt;
+	global $context, $scripturl, $modSettings, $txt;
 
 	echo '
 		<div class="cat_bar">

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

@@ -12,7 +12,7 @@
 
 function template_main()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	// Some javascript for adding more options.
 	echo '

+ 4 - 4
Themes/default/Post.template.php

@@ -916,7 +916,7 @@ function template_main()
 // The template for the spellchecker.
 function template_spellcheck()
 {
-	global $context, $settings, $options, $txt;
+	global $context, $settings, $txt;
 
 	// The style information that makes the spellchecker look... like the forum hopefully!
 	echo '<!DOCTYPE html>
@@ -990,7 +990,7 @@ function template_spellcheck()
 
 function template_quotefast()
 {
-	global $context, $settings, $options, $txt;
+	global $context, $settings, $txt;
 
 	echo '<!DOCTYPE html>
 <html', $context['right_to_left'] ? ' dir="rtl"' : '', '>
@@ -1041,7 +1041,7 @@ function template_quotefast()
 
 function template_announce()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="announcement">
@@ -1088,7 +1088,7 @@ function template_announce()
 
 function template_announcement_send()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="announcement">

+ 21 - 21
Themes/default/Profile.template.php

@@ -13,7 +13,7 @@
 // Template for the profile side bar - goes before any other profile template.
 function template_profile_above()
 {
-	global $context, $settings, $options, $scripturl, $modSettings, $txt;
+	global $context, $settings, $scripturl, $modSettings, $txt;
 
 	echo '
 	<script src="', $settings['default_theme_url'], '/scripts/profile.js"></script>';
@@ -132,7 +132,7 @@ function template_alerts_popup()
 // This template displays users details without any option to edit them.
 function template_summary()
 {
-	global $context, $settings, $options, $scripturl, $modSettings, $txt;
+	global $context, $settings, $scripturl, $modSettings, $txt;
 
 	// Display the basic information about the user
 	echo '
@@ -418,7 +418,7 @@ function template_summary()
 // Template for showing all the posts of the user, in chronological order.
 function template_showPosts()
 {
-	global $context, $options, $scripturl, $modSettings, $txt;
+	global $context, $scripturl, $modSettings, $txt;
 
 	echo '
 		<div class="cat_bar">
@@ -515,7 +515,7 @@ function template_showPosts()
 // Template for showing all the drafts of the user.
 function template_showDrafts()
 {
-	global $context, $settings, $options, $scripturl, $modSettings, $txt;
+	global $context, $settings, $scripturl, $modSettings, $txt;
 
 	echo '
 		<div class="cat_bar">
@@ -581,7 +581,7 @@ function template_showDrafts()
 // Template for showing all the buddies of the current user.
 function template_editBuddies()
 {
-	global $context, $settings, $options, $scripturl, $modSettings, $txt;
+	global $context, $settings, $scripturl, $modSettings, $txt;
 
 	$disabled_fields = isset($modSettings['disabled_profile_fields']) ? array_flip(explode(',', $modSettings['disabled_profile_fields'])) : array();
 	$buddy_fields = array('icq', 'aim', 'yim', 'skype');
@@ -703,7 +703,7 @@ function template_editBuddies()
 // Template for showing the ignore list of the current user.
 function template_editIgnoreList()
 {
-	global $context, $settings, $options, $scripturl, $modSettings, $txt;
+	global $context, $settings, $scripturl, $modSettings, $txt;
 
 	if (!empty($context['saved_successful']))
 		echo '
@@ -812,7 +812,7 @@ function template_editIgnoreList()
 // This template shows an admin information on a users IP addresses used and errors attributed to them.
 function template_trackActivity()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	// The first table shows IP information about the user.
 	echo '
@@ -871,7 +871,7 @@ function template_trackActivity()
 // The template for trackIP, allowing the admin to see where/who a certain IP has been used.
 function template_trackIP()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	// This function always defaults to the last IP used by a member but can be set to track any IP.
 	// The first table in the template gives an input box to allow the admin to enter another IP to track.
@@ -960,7 +960,7 @@ function template_trackIP()
 
 function template_showPermissions()
 {
-	global $context, $settings, $options, $scripturl, $txt;
+	global $context, $settings, $scripturl, $txt;
 
 	echo '
 		<div class="cat_bar">
@@ -1116,7 +1116,7 @@ function template_showPermissions()
 // Template for user statistics, showing graphs and the like.
 function template_statPanel()
 {
-	global $context, $options, $scripturl, $modSettings, $txt;
+	global $context, $scripturl, $modSettings, $txt;
 
 	// First, show a few text statistics such as post/topic count.
 	echo '
@@ -1274,7 +1274,7 @@ function template_statPanel()
 // Template for editing profile options.
 function template_edit_options()
 {
-	global $context, $settings, $options, $scripturl, $modSettings, $txt;
+	global $context, $settings, $scripturl, $modSettings, $txt;
 
 	// The main header!
 	echo '
@@ -1515,7 +1515,7 @@ function template_edit_options()
 // Personal Message settings.
 function template_profile_pm_settings()
 {
-	global $context, $options, $scripturl, $modSettings, $txt;
+	global $context, $scripturl, $modSettings, $txt;
 
 	echo '
 								<dt>
@@ -1592,7 +1592,7 @@ function template_profile_pm_settings()
 // Template for showing theme settings. Note: template_options() actually adds the theme specific options.
 function template_profile_theme_settings()
 {
-	global $context, $options, $scripturl, $modSettings, $txt;
+	global $context, $scripturl, $modSettings, $txt;
 
 	echo '
 							<dt>
@@ -1749,7 +1749,7 @@ function template_profile_theme_settings()
 
 function template_alert_configuration()
 {
-	global $context, $settings, $options, $txt, $scripturl, $modSettings;
+	global $context, $settings, $txt, $scripturl, $modSettings;
 
 	echo '
 		<div class="cat_bar">
@@ -1939,7 +1939,7 @@ function template_alert_configuration()
 
 function template_alert_notifications_topics()
 {
-	global $context, $options, $txt, $scripturl, $modSettings;
+	global $txt;
 
 	// The main containing header.
 	echo '
@@ -1956,7 +1956,7 @@ function template_alert_notifications_topics()
 
 function template_alert_notifications_boards()
 {
-	global $context, $options, $txt, $scripturl, $modSettings;
+	global $txt;
 
 	echo '
 		<div class="cat_bar">
@@ -1973,7 +1973,7 @@ function template_alert_notifications_boards()
 // Template for choosing group membership.
 function template_groupMembership()
 {
-	global $context, $settings, $options, $scripturl, $modSettings, $txt;
+	global $context, $settings, $scripturl, $modSettings, $txt;
 
 	// The main containing header.
 	echo '
@@ -2292,7 +2292,7 @@ function template_viewWarning()
 // Show a lovely interface for issuing warnings.
 function template_issueWarning()
 {
-	global $context, $settings, $options, $scripturl, $modSettings, $txt;
+	global $context, $settings, $scripturl, $modSettings, $txt;
 
 	template_load_warning_variables();
 
@@ -2618,7 +2618,7 @@ function template_issueWarning()
 // Template to show for deleting a users account - now with added delete post capability!
 function template_deleteAccount()
 {
-	global $context, $settings, $options, $scripturl, $txt;
+	global $context, $settings, $scripturl, $txt;
 
 	// The main containing header.
 	echo '
@@ -2706,7 +2706,7 @@ function template_deleteAccount()
 // Template for the password box/save button stuck at the bottom of every profile page.
 function template_profile_save()
 {
-	global $context, $options, $txt;
+	global $context, $txt;
 
 	echo '
 
@@ -3098,7 +3098,7 @@ function template_profile_smiley_pick()
 // Change the way you login to the forum.
 function template_authentication_method()
 {
-	global $context, $settings, $options, $scripturl, $modSettings, $txt;
+	global $context, $settings, $scripturl, $modSettings, $txt;
 
 	// The main header!
 	echo '

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

@@ -12,7 +12,7 @@
 
 function template_recent()
 {
-	global $context, $settings, $options, $txt, $scripturl;
+	global $context, $settings, $txt, $scripturl;
 
 	echo '
 	<div id="recent" class="main_section">
@@ -80,7 +80,7 @@ function template_recent()
 
 function template_unread()
 {
-	global $context, $settings, $options, $txt, $scripturl, $modSettings;
+	global $context, $settings, $txt, $scripturl, $modSettings;
 
 	echo '
 	<div id="recent" class="main_content">';
@@ -231,7 +231,7 @@ function template_unread()
 
 function template_replies()
 {
-	global $context, $settings, $options, $txt, $scripturl, $modSettings;
+	global $context, $settings, $txt, $scripturl, $modSettings;
 
 	echo '
 	<div id="recent">';

+ 9 - 9
Themes/default/Register.template.php

@@ -15,7 +15,7 @@
  */
 function template_registration_agreement()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 		<form action="', $scripturl, '?action=register" method="post" accept-charset="', $context['character_set'], '" id="registration">
@@ -48,7 +48,7 @@ function template_registration_agreement()
 // Before registering - get their information.
 function template_registration_form()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	echo '
 		<script src="', $settings['default_theme_url'], '/scripts/register.js"></script>
@@ -365,7 +365,7 @@ function template_registration_form()
 // After registration... all done ;).
 function template_after()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	// Not much to see here, just a quick... "you're now registered!" or what have you.
 	echo '
@@ -382,7 +382,7 @@ function template_after()
 // Template for giving instructions about COPPA activation.
 function template_coppa()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	// Formulate a nice complicated message!
 	echo '
@@ -431,7 +431,7 @@ function template_coppa()
 // An easily printable form for giving permission to access the forum for a minor.
 function template_coppa_form()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	// Show the form (As best we can)
 	echo '
@@ -462,7 +462,7 @@ function template_coppa_form()
 // Show a window containing the spoken verification code.
 function template_verification_sound()
 {
-	global $context, $settings, $options, $txt, $scripturl;
+	global $context, $settings, $txt, $scripturl;
 
 	echo '<!DOCTYPE html>
 <html', $context['right_to_left'] ? ' dir="rtl"' : '', '>
@@ -503,7 +503,7 @@ function template_verification_sound()
 
 function template_admin_register()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	echo '
 	<script src="', $settings['default_theme_url'], '/scripts/register.js"></script>
@@ -595,7 +595,7 @@ function template_admin_register()
 // Form for editing the agreement shown for people registering to the forum.
 function template_edit_agreement()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	if (!empty($context['saved_successful']))
 		echo '
@@ -671,7 +671,7 @@ function template_edit_agreement()
 
 function template_edit_reserved_words()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	if (!empty($context['saved_successful']))
 		echo '

+ 4 - 4
Themes/default/Reminder.template.php

@@ -12,7 +12,7 @@
 
 function template_main()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<br />
@@ -38,7 +38,7 @@ function template_main()
 
 function template_reminder_pick()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<br />
@@ -84,7 +84,7 @@ function template_sent()
 
 function template_set_password()
 {
-	global $context, $settings, $options, $txt, $scripturl, $modSettings;
+	global $context, $settings, $txt, $scripturl, $modSettings;
 
 	echo '
 	<script src="', $settings['default_theme_url'], '/scripts/register.js"></script>
@@ -133,7 +133,7 @@ function template_set_password()
 
 function template_ask()
 {
-	global $context, $settings, $options, $txt, $scripturl, $modSettings;
+	global $context, $settings, $txt, $scripturl, $modSettings;
 
 	echo '
 	<script src="', $settings['default_theme_url'], '/scripts/register.js"></script>

+ 4 - 4
Themes/default/Reports.template.php

@@ -13,7 +13,7 @@
 // Choose which type of report to run?
 function template_report_type()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">
@@ -52,7 +52,7 @@ function template_report_type()
 // This is the standard template for showing reports in.
 function template_main()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">
@@ -144,7 +144,7 @@ function template_main()
 // Header of the print page!
 function template_print_above()
 {
-	global $context, $settings, $options, $txt;
+	global $context, $settings, $txt;
 
 	echo '<!DOCTYPE html>
 <html', $context['right_to_left'] ? ' dir="rtl"' : '', '>
@@ -158,7 +158,7 @@ function template_print_above()
 
 function template_print()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	// Go through each table!
 	foreach ($context['tables'] as $table)

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

@@ -12,7 +12,7 @@
 
 function template_main()
 {
-	global $context, $settings, $options, $txt, $scripturl, $modSettings;
+	global $context, $settings, $txt, $scripturl, $modSettings;
 
 	echo '
 	<form action="', $scripturl, '?action=search2" method="post" accept-charset="', $context['character_set'], '" name="searchform" id="searchform">

+ 3 - 3
Themes/default/SendTopic.template.php

@@ -39,7 +39,7 @@
 // This is where we get information about who they want to send the topic to, etc.
 function template_main()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="send_topic">
@@ -102,7 +102,7 @@ function template_main()
 // Send an email to a user!
 function template_custom_email()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="send_topic">
@@ -195,7 +195,7 @@ function template_custom_email()
 
 function template_report()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="report_topic">

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

@@ -12,7 +12,7 @@
 
 function template_options()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	$context['theme_options'] = array(
 		array(
@@ -134,7 +134,7 @@ function template_options()
 
 function template_settings()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	$context['theme_settings'] = array(
 		array(

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

@@ -12,7 +12,7 @@
 
 function template_ask()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="split_topics">
@@ -51,7 +51,7 @@ function template_ask()
 
 function template_main()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="split_topics">
@@ -79,7 +79,7 @@ function template_main()
 
 function template_select()
 {
-	global $context, $settings, $options, $txt, $scripturl;
+	global $context, $settings, $txt, $scripturl;
 
 	echo '
 	<div id="split_topics">
@@ -229,7 +229,7 @@ function template_select()
 
 function template_merge_done()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 		<div id="merge_topics">
@@ -256,7 +256,7 @@ function template_merge_done()
 
 function template_merge()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 		<div id="merge_topics">
@@ -358,7 +358,7 @@ function template_merge()
 
 function template_merge_extra_options()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<div id="merge_topics">

+ 13 - 13
Themes/default/Themes.template.php

@@ -13,7 +13,7 @@
 // The main sub template - for theme administration.
 function template_main()
 {
-	global $context, $settings, $options, $scripturl, $txt, $modSettings;
+	global $context, $settings, $scripturl, $txt, $modSettings;
 
 	echo '
 	<div id="admincenter">';
@@ -199,7 +199,7 @@ function template_main()
 
 function template_list_themes()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 	global $modSettings;
 
 	// Show a nice confirmation message.
@@ -302,7 +302,7 @@ function template_list_themes()
 
 function template_reset_list()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<div id="admincenter">
@@ -349,7 +349,7 @@ function template_reset_list()
 
 function template_set_options()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<div id="admincenter">
@@ -449,7 +449,7 @@ function template_set_options()
 
 function template_set_settings()
 {
-	global $context, $settings, $options, $scripturl, $txt;
+	global $context, $settings, $scripturl, $txt;
 
 	echo '
 	<div id="admin_form_wrapper">
@@ -672,7 +672,7 @@ function template_set_settings()
 // This template allows for the selection of different themes ;).
 function template_pick()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<div id="pick_theme">
@@ -766,7 +766,7 @@ function template_pick()
 // Okay, that theme was installed/updated successfully!
 function template_installed()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	// The aftermath.
 	echo '
@@ -802,7 +802,7 @@ function template_installed()
 
 function template_edit_list()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<div id="admin_form_wrapper">
@@ -841,7 +841,7 @@ function template_edit_list()
 
 function template_copy_template()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<div id="admincenter">
@@ -884,7 +884,7 @@ function template_copy_template()
 
 function template_edit_browse()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<div id="admincenter">
@@ -933,7 +933,7 @@ function template_edit_browse()
 // Wanna edit the stylesheet?
 function template_edit_style()
 {
-	global $context, $settings, $options, $scripturl, $txt;
+	global $context, $settings, $scripturl, $txt;
 
 	if ($context['session_error'])
 		echo '
@@ -1086,7 +1086,7 @@ function template_edit_style()
 // This edits the template...
 function template_edit_template()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	if ($context['session_error'])
 		echo '
@@ -1143,7 +1143,7 @@ function template_edit_template()
 
 function template_edit_file()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	if ($context['session_error'])
 		echo '

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

@@ -13,7 +13,7 @@
 // The only template in the file.
 function template_main()
 {
-	global $context, $settings, $options, $scripturl, $txt;
+	global $context, $settings, $scripturl, $txt;
 
 	// Display the table header and linktree.
 	echo '

+ 26 - 26
Themes/default/Wireless.template.php

@@ -24,7 +24,7 @@ function template_wap_above()
 // This is the board index (main page) in WAP 1.1.
 function template_wap_boardindex()
 {
-	global $context, $options, $scripturl;
+	global $context, $scripturl;
 
 	// This is the "main" card...
 	echo '
@@ -65,7 +65,7 @@ function template_wap_boardindex()
 // This is the message index (list of topics in a board) for WAP 1.1.
 function template_wap_messageindex()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<card id="main" title="', $context['page_title'], '">
@@ -99,7 +99,7 @@ function template_wap_messageindex()
 
 function template_wap_display()
 {
-	global $context, $options, $txt;
+	global $context, $txt;
 
 	echo '
 	<card id="main" title="', $context['page_title'], '">
@@ -179,7 +179,7 @@ function template_wap_login()
 
 function template_wap_recent()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 	<card id="recent" title="', $context['page_title'], '">
@@ -205,7 +205,7 @@ function template_wap_recent()
 
 function template_wap_error()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 	<card id="main" title="', $context['page_title'], '">
@@ -217,7 +217,7 @@ function template_wap_error()
 
 function template_wap_below()
 {
-	global $context, $options, $txt;
+	global $context, $txt;
 
 	echo '
 	<card id="switch" title="', $txt['wireless_go_to_full_version'], '">
@@ -231,7 +231,7 @@ function template_wap_below()
 // The cHTML protocol used for i-mode starts here.
 function template_imode_above()
 {
-	global $context, $options, $user_info;
+	global $context, $user_info;
 
 	echo '<!DOCTYPE HTML PUBLIC "-//W3C//DTD Compact HTML 1.0 Draft//EN">
 <html', $context['right_to_left'] ? ' dir="rtl"' : '', '>
@@ -251,7 +251,7 @@ function template_imode_above()
 
 function template_imode_boardindex()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 		<table border="0" cellspacing="0" cellpadding="0">
@@ -294,7 +294,7 @@ function template_imode_boardindex()
 
 function template_imode_messageindex()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 		<table border="0" cellspacing="0" cellpadding="0">
@@ -333,7 +333,7 @@ function template_imode_messageindex()
 
 function template_imode_display()
 {
-	global $context, $options, $scripturl, $board, $txt;
+	global $context, $scripturl, $board, $txt;
 
 	echo '
 		<table border="0" cellspacing="0" cellpadding="0">
@@ -453,7 +453,7 @@ function template_imode_post()
 
 function template_imode_login()
 {
-	global $context, $options, $scripturl, $txt, $modSettings;
+	global $context, $scripturl, $txt, $modSettings;
 
 	echo '
 		<form action="', $scripturl, '?action=login2;imode" method="post">
@@ -486,7 +486,7 @@ function template_imode_login()
 
 function template_imode_pm()
 {
-	global $context, $options, $scripturl, $txt, $user_info;
+	global $context, $scripturl, $txt, $user_info;
 
 	if ($_REQUEST['action'] == 'findmember')
 	{
@@ -702,7 +702,7 @@ function template_imode_pm()
 
 function template_imode_recent()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 		<table border="0" cellspacing="0" cellpadding="0">
@@ -733,7 +733,7 @@ function template_imode_recent()
 
 function template_imode_error()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 		<table border="0" cellspacing="0" cellpadding="0">
@@ -745,7 +745,7 @@ function template_imode_error()
 
 function template_imode_profile()
 {
-	global $context, $options, $scripturl, $board, $txt;
+	global $context, $scripturl, $board, $txt;
 
 	echo '
 		<table border="0" cellspacing="0" cellpadding="0">
@@ -795,7 +795,7 @@ function template_imode_profile()
 
 function template_imode_ban_edit()
 {
-	global $context, $options, $scripturl, $board, $txt, $modSettings;
+	global $context, $scripturl, $board, $txt, $modSettings;
 
 	echo '
 	<form action="', $scripturl, '?action=admin;area=ban;sa=add;imode" method="post">
@@ -878,7 +878,7 @@ function template_imode_ban_edit()
 
 function template_imode_below()
 {
-	global $context, $options, $txt;
+	global $context, $txt;
 
 	echo '
 		<br /><a href="', $context['linktree'][count($context['linktree']) - 1]['url'], (count($context['linktree']) > 1 ? ';' : '?'), 'nowap" rel="nofollow">', $txt['wireless_go_to_full_version'], '</a>
@@ -889,7 +889,7 @@ function template_imode_below()
 // XHTMLMP (XHTML Mobile Profile) templates used for WAP 2.0 start here
 function template_wap2_above()
 {
-	global $context, $settings, $options, $user_info;
+	global $context, $settings, $user_info;
 
 	echo '<?xml version="1.0" encoding="', $context['character_set'], '"?', '>
 <!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.0//EN" "http://www.wapforum.org/DTD/xhtml-mobile10.dtd">
@@ -910,7 +910,7 @@ function template_wap2_above()
 
 function template_wap2_boardindex()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 		<p class="catbg">', $context['forum_name_html_safe'], '</p>';
@@ -951,7 +951,7 @@ function template_wap2_boardindex()
 
 function template_wap2_messageindex()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 		<p class="catbg">', $context['name'], '</p>';
@@ -989,7 +989,7 @@ function template_wap2_messageindex()
 
 function template_wap2_display()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 		<p class="titlebg">' . $context['linktree'][1]['name'] . ' > ' . $context['linktree'][count($context['linktree']) - 2]['name'] . '</p>
@@ -1146,7 +1146,7 @@ function template_wap2_post()
 
 function template_wap2_pm()
 {
-	global $context, $options, $scripturl, $txt, $user_info;
+	global $context, $scripturl, $txt, $user_info;
 
 	if ($_REQUEST['action'] == 'findmember')
 	{
@@ -1352,7 +1352,7 @@ function template_wap2_pm()
 
 function template_wap2_recent()
 {
-	global $context, $options, $scripturl, $txt;
+	global $context, $scripturl, $txt;
 
 	echo '
 		<p class="catbg">', $_REQUEST['action'] == 'unread' ? $txt['wireless_recent_unread_posts'] : $txt['wireless_recent_unread_replies'], '</p>';
@@ -1381,7 +1381,7 @@ function template_wap2_recent()
 
 function template_wap2_error()
 {
-	global $context, $options, $txt, $scripturl;
+	global $context, $txt, $scripturl;
 
 	echo '
 		<p class="catbg">', $context['error_title'], '</p>
@@ -1391,7 +1391,7 @@ function template_wap2_error()
 
 function template_wap2_profile()
 {
-	global $context, $options, $scripturl, $board, $txt;
+	global $context, $scripturl, $board, $txt;
 
 	echo '
 		<p class="catbg">', $txt['summary'], ' - ', $context['member']['name'], '</p>
@@ -1429,7 +1429,7 @@ function template_wap2_profile()
 
 function template_wap2_ban_edit()
 {
-	global $context, $options, $scripturl, $board, $txt, $modSettings;
+	global $context, $scripturl, $board, $txt, $modSettings;
 
 	echo '
 	<form action="', $scripturl, '?action=admin;area=ban;sa=add;wap2" method="post">

+ 7 - 7
Themes/default/Xml.template.php

@@ -44,7 +44,7 @@ function template_modifyfast()
 
 function template_modifydone()
 {
-	global $context, $options, $txt;
+	global $context, $txt;
 
 	echo '<', '?xml version="1.0" encoding="', $context['character_set'], '"?', '>
 <smf>
@@ -70,7 +70,7 @@ function template_modifydone()
 
 function template_modifytopicdone()
 {
-	global $context, $options, $txt;
+	global $context, $txt;
 
 	echo '<', '?xml version="1.0" encoding="', $context['character_set'], '"?', '>
 <smf>
@@ -97,7 +97,7 @@ function template_modifytopicdone()
 
 function template_post()
 {
-	global $context, $options, $txt;
+	global $context, $txt;
 
 	echo '<', '?xml version="1.0" encoding="', $context['character_set'], '"?', '>
 <smf>
@@ -142,7 +142,7 @@ function template_post()
 
 function template_pm()
 {
-	global $context, $options, $txt;
+	global $context, $txt;
 
 	// @todo something could be removed...otherwise it can be merged again with template_post
 	echo '<', '?xml version="1.0" encoding="', $context['character_set'], '"?', '>
@@ -171,7 +171,7 @@ function template_pm()
 
 function template_stats()
 {
-	global $context, $options, $txt, $modSettings;
+	global $context, $txt, $modSettings;
 
 	echo '<', '?xml version="1.0" encoding="', $context['character_set'], '"?', '>
 <smf>';
@@ -192,7 +192,7 @@ function template_stats()
 
 function template_split()
 {
-	global $context, $options;
+	global $context;
 
 	echo '<', '?xml version="1.0" encoding="', $context['character_set'], '"?', '>
 <smf>
@@ -232,7 +232,7 @@ if (!function_exists('template_button_strip'))
 
 function template_results()
 {
-	global $context, $options, $txt;
+	global $context, $txt;
 	echo '<', '?xml version="1.0" encoding="', $context['character_set'], '"?', '>
 <smf>';