diff options
29 files changed, 191 insertions, 150 deletions
diff --git a/code_sniffer/phpbb/Sniffs/Commenting/FileCommentSniff.php b/code_sniffer/phpbb/Sniffs/Commenting/FileCommentSniff.php index ba2b40ecba..68e9e6bb86 100644 --- a/code_sniffer/phpbb/Sniffs/Commenting/FileCommentSniff.php +++ b/code_sniffer/phpbb/Sniffs/Commenting/FileCommentSniff.php @@ -35,7 +35,7 @@ class phpbb_Sniffs_Commenting_FileCommentSniff implements PHP_CodeSniffer_Sniff  	* @param int				  $stackPtr  The position of the current token  	*										in the stack passed in $tokens.  	* -	* @return void +	* @return null  	*/  	public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr)  	{ @@ -120,7 +120,7 @@ class phpbb_Sniffs_Commenting_FileCommentSniff implements PHP_CodeSniffer_Sniff  	 * @param integer The stack pointer for the first comment token.  	 * @param array(string=>array) $tags The found file doc comment tags.  	 *  -	 * @return void +	 * @return null  	 */  	protected function processPackage(PHP_CodeSniffer_File $phpcsFile, $ptr, $tags)  	{ @@ -143,7 +143,7 @@ class phpbb_Sniffs_Commenting_FileCommentSniff implements PHP_CodeSniffer_Sniff       * @param integer The stack pointer for the first comment token.       * @param array(string=>array) $tags The found file doc comment tags.       *  -     * @return void +     * @return null  	 */  	protected function processVersion(PHP_CodeSniffer_File $phpcsFile, $ptr, $tags)      { @@ -166,7 +166,7 @@ class phpbb_Sniffs_Commenting_FileCommentSniff implements PHP_CodeSniffer_Sniff       * @param integer The stack pointer for the first comment token.       * @param array(string=>array) $tags The found file doc comment tags.       *  -     * @return void +     * @return null       */      protected function processCopyright(PHP_CodeSniffer_File $phpcsFile, $ptr, $tags)      { @@ -189,7 +189,7 @@ class phpbb_Sniffs_Commenting_FileCommentSniff implements PHP_CodeSniffer_Sniff       * @param integer The stack pointer for the first comment token.       * @param array(string=>array) $tags The found file doc comment tags.       *  -     * @return void +     * @return null       */      protected function processLicense(PHP_CodeSniffer_File $phpcsFile, $ptr, $tags)      { diff --git a/phpBB/adm/style/ajax.js b/phpBB/adm/style/ajax.js index a3a77df89b..3ccb368665 100644 --- a/phpBB/adm/style/ajax.js +++ b/phpBB/adm/style/ajax.js @@ -36,7 +36,7 @@ phpbb.add_ajax_callback('row_down', function() {  			overlay: false  		}); -		tr_swap.find('.up').html(img_templates.up_disabled); +		tr_swap.find('.up').html(img_templates.up_disabled.clone());  	}  	tr.insertAfter(tr_swap); @@ -48,7 +48,7 @@ phpbb.add_ajax_callback('row_down', function() {  	*/  	if (tr.is(':last-child'))  	{ -		tr.find('.down').html(img_templates.down_disabled); +		tr.find('.down').html(img_templates.down_disabled.clone());  		var down_img = img_templates.down.clone().attr('href', tr_swap.attr('data-down'));  		tr_swap.find('.down').html(down_img); @@ -82,7 +82,7 @@ phpbb.add_ajax_callback('row_up', function() {  			overlay: false  		}); -		tr_swap.find('.down').html(img_templates.down_disabled); +		tr_swap.find('.down').html(img_templates.down_disabled.clone());  	}  	tr.insertBefore(tr_swap); @@ -94,7 +94,7 @@ phpbb.add_ajax_callback('row_up', function() {  	*/  	if (tr.is(':first-child'))  	{ -		tr.find('.up').html(img_templates.up_disabled); +		tr.find('.up').html(img_templates.up_disabled.clone());  		var up_img = img_templates.up.clone().attr('href', tr_swap.attr('data-up'));  		tr_swap.find('.up').html(up_img); diff --git a/phpBB/composer.json b/phpBB/composer.json index 5a03e68f73..d2536a73cf 100644 --- a/phpBB/composer.json +++ b/phpBB/composer.json @@ -9,6 +9,6 @@  		"symfony/yaml": "2.1.*"  	},  	"require-dev": { -		"fabpot/goutte": "1.0.x-dev" +		"fabpot/goutte": "v0.1.0"  	}  } diff --git a/phpBB/composer.lock b/phpBB/composer.lock index 62ece6d505..e96c15fe8b 100644 --- a/phpBB/composer.lock +++ b/phpBB/composer.lock @@ -1,5 +1,5 @@  { -    "hash": "efb4768ba71d7cd2c84baa0610d84067", +    "hash": "c1a76530df6b9daa16b8033d61b76503",      "packages": [          {              "name": "symfony/config", @@ -381,29 +381,29 @@      "packages-dev": [          {              "name": "fabpot/goutte", -            "version": "dev-master", +            "version": "v0.1.0",              "source": {                  "type": "git",                  "url": "https://github.com/fabpot/Goutte", -                "reference": "f2940f9c7c1f409159f5e9f512e575946c5cff48" +                "reference": "v0.1.0"              },              "dist": {                  "type": "zip", -                "url": "https://github.com/fabpot/Goutte/archive/f2940f9c7c1f409159f5e9f512e575946c5cff48.zip", -                "reference": "f2940f9c7c1f409159f5e9f512e575946c5cff48", +                "url": "https://github.com/fabpot/Goutte/archive/v0.1.0.zip", +                "reference": "v0.1.0",                  "shasum": ""              },              "require": {                  "php": ">=5.3.0", +                "ext-curl": "*",                  "symfony/browser-kit": "2.1.*",                  "symfony/css-selector": "2.1.*",                  "symfony/dom-crawler": "2.1.*",                  "symfony/finder": "2.1.*",                  "symfony/process": "2.1.*", -                "ext-curl": "*", -                "guzzle/http": "2.8.*" +                "guzzle/guzzle": "3.0.*"              }, -            "time": "1351086217", +            "time": "2012-12-02 13:44:35",              "type": "application",              "extra": {                  "branch-alias": { @@ -432,126 +432,90 @@              ]          },          { -            "name": "guzzle/common", -            "version": "v2.8.8", -            "target-dir": "Guzzle/Common", +            "name": "guzzle/guzzle", +            "version": "v3.0.5",              "source": {                  "type": "git", -                "url": "git://github.com/guzzle/common.git", -                "reference": "v2.8.8" +                "url": "https://github.com/guzzle/guzzle", +                "reference": "v3.0.5"              },              "dist": {                  "type": "zip", -                "url": "https://github.com/guzzle/common/zipball/v2.8.8", -                "reference": "v2.8.8", +                "url": "https://github.com/guzzle/guzzle/archive/v3.0.5.zip", +                "reference": "v3.0.5",                  "shasum": ""              },              "require": {                  "php": ">=5.3.2", +                "ext-curl": "*",                  "symfony/event-dispatcher": "2.1.*"              }, -            "time": "2012-10-15 17:42:47", -            "type": "library", -            "installation-source": "dist", -            "autoload": { -                "psr-0": { -                    "Guzzle\\Common": "" -                } -            }, -            "license": [ -                "MIT" -            ], -            "description": "Common libraries used by Guzzle", -            "homepage": "http://guzzlephp.org/", -            "keywords": [ -                "log", -                "event", -                "cache", -                "validation", -                "Socket", -                "common", -                "batch", -                "inflection" -            ] -        }, -        { -            "name": "guzzle/http", -            "version": "v2.8.8", -            "target-dir": "Guzzle/Http", -            "source": { -                "type": "git", -                "url": "git://github.com/guzzle/http.git", -                "reference": "v2.8.8" -            }, -            "dist": { -                "type": "zip", -                "url": "https://github.com/guzzle/http/zipball/v2.8.8", -                "reference": "v2.8.8", -                "shasum": "" -            }, -            "require": { -                "php": ">=5.3.2", +            "replace": { +                "guzzle/batch": "self.version", +                "guzzle/cache": "self.version",                  "guzzle/common": "self.version", -                "guzzle/parser": "self.version" +                "guzzle/http": "self.version", +                "guzzle/inflection": "self.version", +                "guzzle/iterator": "self.version", +                "guzzle/log": "self.version", +                "guzzle/parser": "self.version", +                "guzzle/plugin": "self.version", +                "guzzle/plugin-async": "self.version", +                "guzzle/plugin-backoff": "self.version", +                "guzzle/plugin-cache": "self.version", +                "guzzle/plugin-cookie": "self.version", +                "guzzle/plugin-curlauth": "self.version", +                "guzzle/plugin-history": "self.version", +                "guzzle/plugin-log": "self.version", +                "guzzle/plugin-md5": "self.version", +                "guzzle/plugin-mock": "self.version", +                "guzzle/plugin-oauth": "self.version", +                "guzzle/service": "self.version", +                "guzzle/stream": "self.version"              }, -            "time": "2012-10-15 17:42:47", +            "require-dev": { +                "doctrine/common": "*", +                "symfony/class-loader": "*", +                "monolog/monolog": "1.*", +                "zendframework/zend-cache": "2.0.*", +                "zendframework/zend-log": "2.0.*", +                "zend/zend-log1": "1.12", +                "zend/zend-cache1": "1.12", +                "phpunit/phpunit": "3.7.*" +            }, +            "time": "2012-11-19 00:15:33",              "type": "library",              "installation-source": "dist",              "autoload": {                  "psr-0": { -                    "Guzzle\\Http": "" +                    "Guzzle\\Tests": "tests/", +                    "Guzzle": "src/"                  }              },              "license": [                  "MIT"              ], -            "description": "HTTP libraries used by Guzzle", +            "authors": [ +                { +                    "name": "Michael Dowling", +                    "email": "mtdowling@gmail.com", +                    "homepage": "https://github.com/mtdowling" +                }, +                { +                    "name": "Guzzle Community", +                    "homepage": "https://github.com/guzzle/guzzle/contributors" +                } +            ], +            "description": "Guzzle is a PHP HTTP client library and framework for building RESTful web service clients",              "homepage": "http://guzzlephp.org/",              "keywords": [ +                "framework",                  "curl",                  "http", +                "rest",                  "http client",                  "client", -                "Guzzle" -            ] -        }, -        { -            "name": "guzzle/parser", -            "version": "v2.8.8", -            "target-dir": "Guzzle/Parser", -            "source": { -                "type": "git", -                "url": "git://github.com/guzzle/parser.git", -                "reference": "v2.8.8" -            }, -            "dist": { -                "type": "zip", -                "url": "https://github.com/guzzle/parser/zipball/v2.8.8", -                "reference": "v2.8.8", -                "shasum": "" -            }, -            "require": { -                "php": ">=5.3.2" -            }, -            "time": "2012-09-20 13:28:06", -            "type": "library", -            "installation-source": "dist", -            "autoload": { -                "psr-0": { -                    "Guzzle\\Parser": "" -                } -            }, -            "license": [ -                "MIT" -            ], -            "description": "Interchangeable parsers used by Guzzle", -            "homepage": "http://guzzlephp.org/", -            "keywords": [ -                "http", -                "url", -                "message", -                "cookie", -                "URI Template" +                "web service"              ]          },          { @@ -808,7 +772,7 @@      ],      "minimum-stability": "beta", -    "stability-flags": { -        "fabpot/goutte": 20 -    } +    "stability-flags": [ + +    ]  } diff --git a/phpBB/includes/config/config.php b/phpBB/includes/config/config.php index 12a4a418b2..4b533dd55c 100644 --- a/phpBB/includes/config/config.php +++ b/phpBB/includes/config/config.php @@ -109,7 +109,7 @@ class phpbb_config implements ArrayAccess, IteratorAggregate, Countable  	* @param  String $key       The configuration option's name  	* @param  bool   $use_cache Whether this variable should be cached or if it  	*                           changes too frequently to be efficiently cached -	* @return void +	* @return null  	*/  	public function delete($key, $use_cache = true)  	{ diff --git a/phpBB/includes/config/db.php b/phpBB/includes/config/db.php index 993a764a7f..45f9f1cb21 100644 --- a/phpBB/includes/config/db.php +++ b/phpBB/includes/config/db.php @@ -96,7 +96,7 @@ class phpbb_config_db extends phpbb_config  	* @param  String $key       The configuration option's name  	* @param  bool   $use_cache Whether this variable should be cached or if it  	*                           changes too frequently to be efficiently cached -	* @return void +	* @return null  	*/  	public function delete($key, $use_cache = true)  	{ diff --git a/phpBB/includes/cron/manager.php b/phpBB/includes/cron/manager.php index ccaa4f3764..84c9650830 100644 --- a/phpBB/includes/cron/manager.php +++ b/phpBB/includes/cron/manager.php @@ -54,7 +54,7 @@ class phpbb_cron_manager  	*  	* @param array|Traversable $tasks		Array of instances of phpbb_cron_task  	* -	* @return void +	* @return null  	*/  	public function load_tasks($tasks)  	{ diff --git a/phpBB/includes/cron/task/core/prune_all_forums.php b/phpBB/includes/cron/task/core/prune_all_forums.php index 252e16e57d..ee0b5f7626 100644 --- a/phpBB/includes/cron/task/core/prune_all_forums.php +++ b/phpBB/includes/cron/task/core/prune_all_forums.php @@ -50,7 +50,7 @@ class phpbb_cron_task_core_prune_all_forums extends phpbb_cron_task_base  	/**  	* Runs this cron task.  	* -	* @return void +	* @return null  	*/  	public function run()  	{ diff --git a/phpBB/includes/cron/task/core/prune_forum.php b/phpBB/includes/cron/task/core/prune_forum.php index 41d60af921..fa7a761d88 100644 --- a/phpBB/includes/cron/task/core/prune_forum.php +++ b/phpBB/includes/cron/task/core/prune_forum.php @@ -70,7 +70,7 @@ class phpbb_cron_task_core_prune_forum extends phpbb_cron_task_base implements p  	/**  	* Runs this cron task.  	* -	* @return void +	* @return null  	*/  	public function run()  	{ @@ -138,7 +138,7 @@ class phpbb_cron_task_core_prune_forum extends phpbb_cron_task_base implements p  	*  	* @param phpbb_request_interface $request Request object.  	* -	* @return void +	* @return null  	*/  	public function parse_parameters(phpbb_request_interface $request)  	{ diff --git a/phpBB/includes/cron/task/core/queue.php b/phpBB/includes/cron/task/core/queue.php index c765660906..732f9c6bea 100644 --- a/phpBB/includes/cron/task/core/queue.php +++ b/phpBB/includes/cron/task/core/queue.php @@ -43,7 +43,7 @@ class phpbb_cron_task_core_queue extends phpbb_cron_task_base  	/**  	* Runs this cron task.  	* -	* @return void +	* @return null  	*/  	public function run()  	{ diff --git a/phpBB/includes/cron/task/core/tidy_cache.php b/phpBB/includes/cron/task/core/tidy_cache.php index 6017eea561..16a45dae7c 100644 --- a/phpBB/includes/cron/task/core/tidy_cache.php +++ b/phpBB/includes/cron/task/core/tidy_cache.php @@ -40,7 +40,7 @@ class phpbb_cron_task_core_tidy_cache extends phpbb_cron_task_base  	/**  	* Runs this cron task.  	* -	* @return void +	* @return null  	*/  	public function run()  	{ diff --git a/phpBB/includes/cron/task/core/tidy_database.php b/phpBB/includes/cron/task/core/tidy_database.php index 1d256f964f..b882e7b500 100644 --- a/phpBB/includes/cron/task/core/tidy_database.php +++ b/phpBB/includes/cron/task/core/tidy_database.php @@ -43,7 +43,7 @@ class phpbb_cron_task_core_tidy_database extends phpbb_cron_task_base  	/**  	* Runs this cron task.  	* -	* @return void +	* @return null  	*/  	public function run()  	{ diff --git a/phpBB/includes/cron/task/core/tidy_search.php b/phpBB/includes/cron/task/core/tidy_search.php index 2e5f3d79d5..fdbe31346e 100644 --- a/phpBB/includes/cron/task/core/tidy_search.php +++ b/phpBB/includes/cron/task/core/tidy_search.php @@ -54,7 +54,7 @@ class phpbb_cron_task_core_tidy_search extends phpbb_cron_task_base  	/**  	* Runs this cron task.  	* -	* @return void +	* @return null  	*/  	public function run()  	{ diff --git a/phpBB/includes/cron/task/core/tidy_sessions.php b/phpBB/includes/cron/task/core/tidy_sessions.php index 13531aa30b..95f55235c9 100644 --- a/phpBB/includes/cron/task/core/tidy_sessions.php +++ b/phpBB/includes/cron/task/core/tidy_sessions.php @@ -40,7 +40,7 @@ class phpbb_cron_task_core_tidy_sessions extends phpbb_cron_task_base  	/**  	* Runs this cron task.  	* -	* @return void +	* @return null  	*/  	public function run()  	{ diff --git a/phpBB/includes/cron/task/core/tidy_warnings.php b/phpBB/includes/cron/task/core/tidy_warnings.php index 8dd0674fe5..2a7798e56e 100644 --- a/phpBB/includes/cron/task/core/tidy_warnings.php +++ b/phpBB/includes/cron/task/core/tidy_warnings.php @@ -45,7 +45,7 @@ class phpbb_cron_task_core_tidy_warnings extends phpbb_cron_task_base  	/**  	* Runs this cron task.  	* -	* @return void +	* @return null  	*/  	public function run()  	{ diff --git a/phpBB/includes/cron/task/parametrized.php b/phpBB/includes/cron/task/parametrized.php index 0714b2e701..5f0e46eafc 100644 --- a/phpBB/includes/cron/task/parametrized.php +++ b/phpBB/includes/cron/task/parametrized.php @@ -46,7 +46,7 @@ interface phpbb_cron_task_parametrized extends phpbb_cron_task  	*  	* @param phpbb_request_interface $request Request object.  	* -	* @return void +	* @return null  	*/  	public function parse_parameters(phpbb_request_interface $request);  } diff --git a/phpBB/includes/cron/task/task.php b/phpBB/includes/cron/task/task.php index 7b08fed413..2d585df96d 100644 --- a/phpBB/includes/cron/task/task.php +++ b/phpBB/includes/cron/task/task.php @@ -31,7 +31,7 @@ interface phpbb_cron_task  	/**  	* Runs this cron task.  	* -	* @return void +	* @return null  	*/  	public function run(); diff --git a/phpBB/includes/functions_download.php b/phpBB/includes/functions_download.php index b6371dbecc..fc6f1cc762 100644 --- a/phpBB/includes/functions_download.php +++ b/phpBB/includes/functions_download.php @@ -433,7 +433,7 @@ function set_modified_headers($stamp, $browser)  *  * @param bool $exit		Whether to die or not.  * -* @return void +* @return null  */  function file_gc($exit = true)  { diff --git a/phpBB/includes/functions_module.php b/phpBB/includes/functions_module.php index ad76be9f2f..0d387ace6d 100644 --- a/phpBB/includes/functions_module.php +++ b/phpBB/includes/functions_module.php @@ -759,7 +759,26 @@ class p_master  				}  			} -			$u_title = $module_url . $delim . 'i=' . (($item_ary['cat']) ? $item_ary['id'] : $item_ary['name'] . (($item_ary['is_duplicate']) ? '&icat=' . $current_id : '') . '&mode=' . $item_ary['mode']); +			$u_title = $module_url . $delim . 'i='; +			// if the item has a name use it, else use its id +			if (empty($item_ary['name'])) +			{ +				$u_title .=  $item_ary['id']; +			} +			else +			{ +				// if the category has a name, then use it. +				$u_title .=  $item_ary['name']; +			} +			// If the item is not a category append the mode +			if (!$item_ary['cat']) +			{ +				if ($item_ary['is_duplicate']) +				{ +					$u_title .= '&icat=' . $current_id; +				} +				$u_title .= '&mode=' . $item_ary['mode']; +			}  			// Was not allowed in categories before - /*!$item_ary['cat'] && */  			$u_title .= (isset($item_ary['url_extra'])) ? $item_ary['url_extra'] : ''; diff --git a/phpBB/includes/group_positions.php b/phpBB/includes/group_positions.php index 74de3516cb..60352ed97d 100644 --- a/phpBB/includes/group_positions.php +++ b/phpBB/includes/group_positions.php @@ -104,7 +104,7 @@ class phpbb_group_positions  	* Addes a group by group_id  	*  	* @param	int		$group_id	group_id of the group to be added -	* @return	void +	* @return	null  	*/  	public function add_group($group_id)  	{ @@ -128,7 +128,7 @@ class phpbb_group_positions  	*  	* @param	int		$group_id		group_id of the group to be deleted  	* @param	bool	$skip_group		Skip setting the group to GROUP_DISABLED, to save the query, when you need to update it anyway. -	* @return	void +	* @return	null  	*/  	public function delete_group($group_id, $skip_group = false)  	{ @@ -159,7 +159,7 @@ class phpbb_group_positions  	* Moves a group up by group_id  	*  	* @param	int		$group_id	group_id of the group to be moved -	* @return	void +	* @return	null  	*/  	public function move_up($group_id)  	{ @@ -170,7 +170,7 @@ class phpbb_group_positions  	* Moves a group down by group_id  	*  	* @param	int		$group_id	group_id of the group to be moved -	* @return	void +	* @return	null  	*/  	public function move_down($group_id)  	{ @@ -184,7 +184,7 @@ class phpbb_group_positions  	* @param	int		$delta		number of steps:  	*								- positive = move up  	*								- negative = move down -	* @return	void +	* @return	null  	*/  	public function move($group_id, $delta)  	{ diff --git a/phpBB/includes/lock/db.php b/phpBB/includes/lock/db.php index fa559d6887..6e94dd5a85 100644 --- a/phpBB/includes/lock/db.php +++ b/phpBB/includes/lock/db.php @@ -125,7 +125,7 @@ class phpbb_lock_db  	* Note: Attempting to release a lock that is already released,  	* that is, calling release() multiple times, is harmless.  	* -	* @return void +	* @return null  	*/  	public function release()  	{ diff --git a/phpBB/includes/style/resource_locator.php b/phpBB/includes/style/resource_locator.php index 04beddb434..4cf767c062 100644 --- a/phpBB/includes/style/resource_locator.php +++ b/phpBB/includes/style/resource_locator.php @@ -110,7 +110,7 @@ class phpbb_style_resource_locator implements phpbb_template_locator  	* Typically it is one directory level deep, e.g. "template/".  	*  	* @param string $template_path Relative path to templates directory within style directories -	* @return void +	* @return null  	*/  	public function set_template_path($template_path)  	{ @@ -121,7 +121,7 @@ class phpbb_style_resource_locator implements phpbb_template_locator  	* Sets the location of templates directory within style directories  	* to the default, which is "template/".  	* -	* @return void +	* @return null  	*/  	public function set_default_template_path()  	{ diff --git a/phpBB/includes/template/compile.php b/phpBB/includes/template/compile.php index 82b301c1a2..d0b3d0f115 100644 --- a/phpBB/includes/template/compile.php +++ b/phpBB/includes/template/compile.php @@ -118,7 +118,7 @@ class phpbb_template_compile  	*  	* @param resource $source_stream Source stream  	* @param resource $dest_stream Destination stream -	* @return void +	* @return null  	*/  	private function compile_stream_to_stream($source_stream, $dest_stream)  	{ diff --git a/phpBB/install/database_update.php b/phpBB/install/database_update.php index 377e38c423..e966756337 100644 --- a/phpBB/install/database_update.php +++ b/phpBB/install/database_update.php @@ -2303,6 +2303,26 @@ function change_database_data(&$no_updates, $version)  				}  			} +			// Disable receiving pms for bots +			$sql = 'SELECT user_id +				FROM ' . BOTS_TABLE; +			$result = $db->sql_query($sql); + +			$bot_user_ids = array(); +			while ($row = $db->sql_fetchrow($result)) +			{ +				$bot_user_ids[] = (int) $row['user_id']; +			} +			$db->sql_freeresult($result); + +			if (!empty($bot_user_ids)) +			{ +				$sql = 'UPDATE ' . USERS_TABLE . ' +					SET user_allow_pm = 0 +					WHERE ' . $db->sql_in_set('user_id', $bot_user_ids); +				_sql($sql, $errored, $error_ary); +			} +  			$no_updates = false;  		break; @@ -2750,6 +2770,28 @@ function change_database_data(&$no_updates, $version)  				$config->set('site_home_text', '');  			} +			// PHPBB3-10601: Make inbox default. Add basename to ucp's pm category +			 +			// Get the category wanted while checking, at the same time, if this has already been applied +			$sql = 'SELECT module_id, module_basename +					FROM ' . MODULES_TABLE . " +					WHERE module_basename <> 'ucp_pm' AND +						module_langname='UCP_PM' +						"; +			$result = $db->sql_query_limit($sql, 1); + +			if ($row = $db->sql_fetchrow($result)) +			{ +				// This update is still not applied. Applying it + +				$sql = 'UPDATE ' . MODULES_TABLE . " +					SET module_basename = 'ucp_pm' +					WHERE  module_id = " . (int) $row['module_id']; + +				_sql($sql, $errored, $error_ary);		 +			} +			$db->sql_freeresult($result); +  		break;  	}  } diff --git a/phpBB/install/install_install.php b/phpBB/install/install_install.php index f80b8b5661..4b2fa046bc 100644 --- a/phpBB/install/install_install.php +++ b/phpBB/install/install_install.php @@ -1478,8 +1478,14 @@ class install_install extends module  			foreach ($this->module_categories[$module_class] as $cat_name => $subs)  			{ +				$basename = ''; +				// Check if this sub-category has a basename. If it has, use it. +				if (isset($this->module_categories_basenames[$cat_name])) +				{ +					$basename = $this->module_categories_basenames[$cat_name]; +				}  				$module_data = array( -					'module_basename'	=> '', +					'module_basename'	=> $basename,  					'module_enabled'	=> 1,  					'module_display'	=> 1,  					'parent_id'			=> 0, @@ -1507,8 +1513,14 @@ class install_install extends module  				{  					foreach ($subs as $level2_name)  					{ +						$basename = ''; +						// Check if this sub-category has a basename. If it has, use it. +						if (isset($this->module_categories_basenames[$level2_name])) +						{ +							$basename = $this->module_categories_basenames[$level2_name]; +						}  						$module_data = array( -							'module_basename'	=> '', +							'module_basename'	=> $basename,  							'module_enabled'	=> 1,  							'module_display'	=> 1,  							'parent_id'			=> (int) $categories[$cat_name]['id'], @@ -1772,6 +1784,7 @@ class install_install extends module  				'user_timezone'			=> 'UTC',  				'user_dateformat'		=> $lang['default_dateformat'],  				'user_allow_massemail'	=> 0, +				'user_allow_pm'			=> 0,  			);  			$user_id = user_add($user_row); @@ -2115,6 +2128,9 @@ class install_install extends module  			'UCP_ZEBRA'			=> null,  		),  	); +	var $module_categories_basenames = array( +		'UCP_PM' => 'ucp_pm', +	);  	var $module_extras = array(  		'acp'	=> array( diff --git a/phpBB/language/en/acp/board.php b/phpBB/language/en/acp/board.php index a4380486cc..1b99c87938 100644 --- a/phpBB/language/en/acp/board.php +++ b/phpBB/language/en/acp/board.php @@ -449,10 +449,10 @@ $lang = array_merge($lang, array(  	'ACP_SECURITY_SETTINGS_EXPLAIN'		=> 'Here you are able to define session and login related settings.',  	'ALL'							=> 'All', -	'ALLOW_AUTOLOGIN'				=> 'Allow persistent logins', -	'ALLOW_AUTOLOGIN_EXPLAIN'		=> 'Determines whether users can autologin when they visit the board.', -	'AUTOLOGIN_LENGTH'				=> 'Persistent login key expiration length (in days)', -	'AUTOLOGIN_LENGTH_EXPLAIN'		=> 'Number of days after which persistent login keys are removed or zero to disable.', +	'ALLOW_AUTOLOGIN'				=> 'Allow "Remember Me" logins', +	'ALLOW_AUTOLOGIN_EXPLAIN'		=> 'Determines whether users are given "Remember Me" option when they visit the board.', +	'AUTOLOGIN_LENGTH'				=> '"Remember Me" login key expiration length (in days)', +	'AUTOLOGIN_LENGTH_EXPLAIN'		=> 'Number of days after which "Remember Me" login keys are removed or zero to disable.',  	'BROWSER_VALID'					=> 'Validate browser',  	'BROWSER_VALID_EXPLAIN'			=> 'Enables browser validation for each session improving security.',  	'CHECK_DNSBL'					=> 'Check IP against DNS Blackhole List', diff --git a/phpBB/language/en/common.php b/phpBB/language/en/common.php index 7ce3b5d2e6..fbb7b40d41 100644 --- a/phpBB/language/en/common.php +++ b/phpBB/language/en/common.php @@ -343,7 +343,7 @@ $lang = array_merge($lang, array(  	'LOGIN_EXPLAIN_VIEWONLINE'			=> 'In order to view the online list you have to be registered and logged in.',  	'LOGOUT'							=> 'Logout',  	'LOGOUT_USER'						=> 'Logout [ %s ]', -	'LOG_ME_IN'							=> 'Log me on automatically each visit', +	'LOG_ME_IN'							=> 'Remember me',  	'MARK'					=> 'Mark',  	'MARK_ALL'				=> 'Mark all', diff --git a/phpBB/language/en/help_faq.php b/phpBB/language/en/help_faq.php index 5c99f81c06..9500943b88 100644 --- a/phpBB/language/en/help_faq.php +++ b/phpBB/language/en/help_faq.php @@ -43,7 +43,7 @@ $help = array(  	),  	array(  		0 => 'Why do I get logged off automatically?', -		1 => 'If you do not check the <em>Log me in automatically</em> box when you login, the board will only keep you logged in for a preset time. This prevents misuse of your account by anyone else. To stay logged in, check the box during login. This is not recommended if you access the board from a shared computer, e.g. library, internet cafe, university computer lab, etc. If you do not see this checkbox, it means the board administrator has disabled this feature.' +		1 => 'If you do not check the <em>Remember me</em> box when you login, the board will only keep you logged in for a preset time. This prevents misuse of your account by anyone else. To stay logged in, check the box during login. This is not recommended if you access the board from a shared computer, e.g. library, internet cafe, university computer lab, etc. If you do not see this checkbox, it means the board administrator has disabled this feature.'  	),  	array(  		0 => 'How do I prevent my username appearing in the online user listings?', diff --git a/phpBB/language/en/ucp.php b/phpBB/language/en/ucp.php index 705b07b170..b919699ea0 100644 --- a/phpBB/language/en/ucp.php +++ b/phpBB/language/en/ucp.php @@ -87,7 +87,7 @@ $lang = array_merge($lang, array(  	'ATTACHMENTS_EXPLAIN'			=> 'This is a list of attachments you have made in posts to this board.',  	'ATTACHMENTS_DELETED'			=> 'Attachments successfully deleted.',  	'ATTACHMENT_DELETED'			=> 'Attachment successfully deleted.', -	'AUTOLOGIN_SESSION_KEYS_DELETED'=> 'The selected persistent login keys were successfully deleted.', +	'AUTOLOGIN_SESSION_KEYS_DELETED'=> 'The selected "Remember Me" login keys were successfully deleted.',  	'AVATAR_CATEGORY'				=> 'Category',  	'AVATAR_EXPLAIN'				=> 'Maximum dimensions; width: %1$s, height: %2$s, file size: %3$.2f KiB.',  	'AVATAR_FEATURES_DISABLED'		=> 'The avatar functionality is currently disabled.', @@ -380,8 +380,8 @@ $lang = array_merge($lang, array(  	'PREFERENCES_UPDATED'		=> 'Your preferences have been updated.',  	'PROFILE_INFO_NOTICE'		=> 'Please note that this information may be viewable to other members. Be careful when including any personal details. Any fields marked with a * must be completed.',  	'PROFILE_UPDATED'			=> 'Your profile has been updated.', -	'PROFILE_AUTOLOGIN_KEYS'	=> 'The persistent login keys automatically log you in when you visit the board. If you logout, the persistent login key is deleted only on the computer you are using to logout. Here you can see persistent login keys created on other computers you used to access this site.', -	'PROFILE_NO_AUTOLOGIN_KEYS'	=> 'There are no saved persistent login keys.', +	'PROFILE_AUTOLOGIN_KEYS'	=> 'The "Remember Me" login keys automatically log you in when you visit the board. If you logout, the remember me login key is deleted only on the computer you are using to logout. Here you can see remember login keys created on other computers you used to access this site.', +	'PROFILE_NO_AUTOLOGIN_KEYS'	=> 'There are no saved "Remember Me" login keys.',  	'RECIPIENT'							=> 'Recipient',  	'RECIPIENTS'						=> 'Recipients', @@ -476,7 +476,7 @@ $lang = array_merge($lang, array(  	'UCP_PROFILE_PROFILE_INFO'	=> 'Edit profile',  	'UCP_PROFILE_REG_DETAILS'	=> 'Edit account settings',  	'UCP_PROFILE_SIGNATURE'		=> 'Edit signature', -	'UCP_PROFILE_AUTOLOGIN_KEYS'=> 'Edit persistent login keys', +	'UCP_PROFILE_AUTOLOGIN_KEYS'=> 'Edit "Remember Me" login keys',  	'UCP_USERGROUPS'			=> 'Usergroups',  	'UCP_USERGROUPS_MEMBER'		=> 'Edit memberships',  | 
