From 4bdad7125a34e121f7857c34480d0527c1925384 Mon Sep 17 00:00:00 2001 From: Igor Wiedler Date: Wed, 13 Jul 2011 11:32:38 +0200 Subject: [ticket/9608] Remove use of references in captcha and other places References are not really needed in PHP due to copy-on-write. Since PHP5, objects are always passed around as identifiers, which means they are mutable. So it is no longer required to pass these by reference either. PHPBB3-9608 --- phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php') diff --git a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php index add8c3959f..bb76a06371 100644 --- a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php +++ b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php @@ -50,9 +50,9 @@ class phpbb_captcha_gd extends phpbb_default_captcha } } - function &get_instance() + function get_instance() { - $instance =& new phpbb_captcha_gd(); + $instance = new phpbb_captcha_gd(); return $instance; } -- cgit v1.2.1 From 7a04c9048c110f0bd21ea3e9e869e17b408d640e Mon Sep 17 00:00:00 2001 From: Unknown Date: Sat, 31 Dec 2011 13:32:52 +0000 Subject: [ticket/9916] Updating header license and removing Version $Id$ PHPBB3-9916 --- phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php') diff --git a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php index bb76a06371..a63b0e448f 100644 --- a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php +++ b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php @@ -2,9 +2,8 @@ /** * * @package VC -* @version $Id$ * @copyright (c) 2006, 2008 phpBB Group -* @license http://opensource.org/licenses/gpl-license.php GNU Public License +* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2 * */ -- cgit v1.2.1 From c8da69d9c26e0017f13abb2c954e52c4cd593fdc Mon Sep 17 00:00:00 2001 From: Bruno Ais Date: Thu, 5 Apr 2012 14:14:40 +0100 Subject: [ticket/10575] Fixing non-static access to static functions get_instance These changes should solve the strict standards error about accessing the non-static get_instance() in a non-static way. For that, I changed the get_instance methods to static methods. PHPBB3-10575 --- phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php') diff --git a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php index a63b0e448f..5b3adee047 100644 --- a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php +++ b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php @@ -49,7 +49,7 @@ class phpbb_captcha_gd extends phpbb_default_captcha } } - function get_instance() + static function get_instance() { $instance = new phpbb_captcha_gd(); return $instance; -- cgit v1.2.1 From 2bf1c4eb32f1e668a215f1dabb42fe88e8a9cd11 Mon Sep 17 00:00:00 2001 From: Bruno Ais Date: Thu, 5 Apr 2012 14:16:56 +0100 Subject: [ticket/10575] Adding public visibility to the methods. Added public visibility to the methods PHPBB3-10575 --- phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php') diff --git a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php index 5b3adee047..6c1f3bf00b 100644 --- a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php +++ b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php @@ -49,7 +49,7 @@ class phpbb_captcha_gd extends phpbb_default_captcha } } - static function get_instance() + public static function get_instance() { $instance = new phpbb_captcha_gd(); return $instance; -- cgit v1.2.1 From 14a6e5ec73779d18cc6f09cb3b1cb4fd08f024f8 Mon Sep 17 00:00:00 2001 From: Oleg Pudeyev Date: Mon, 29 Oct 2012 09:34:51 -0400 Subject: [ticket/11157] Fix remaining captcha spam. PHPBB3-11157 --- phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php') diff --git a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php index 6c1f3bf00b..e4503cabe4 100644 --- a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php +++ b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php @@ -55,7 +55,7 @@ class phpbb_captcha_gd extends phpbb_default_captcha return $instance; } - function is_available() + public static function is_available() { global $phpbb_root_path, $phpEx; @@ -80,7 +80,7 @@ class phpbb_captcha_gd extends phpbb_default_captcha return true; } - function get_name() + public static function get_name() { return 'CAPTCHA_GD'; } -- cgit v1.2.1 From d602f13d7f6ba7ee67a5286befd8afd9f8f0cd15 Mon Sep 17 00:00:00 2001 From: Oleg Pudeyev Date: Mon, 29 Oct 2012 14:54:54 -0400 Subject: [ticket/11157] static public is the currently approved order. PHPBB3-11157 --- phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php') diff --git a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php index e4503cabe4..5328e64a86 100644 --- a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php +++ b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php @@ -55,7 +55,7 @@ class phpbb_captcha_gd extends phpbb_default_captcha return $instance; } - public static function is_available() + static public function is_available() { global $phpbb_root_path, $phpEx; @@ -80,7 +80,7 @@ class phpbb_captcha_gd extends phpbb_default_captcha return true; } - public static function get_name() + static public function get_name() { return 'CAPTCHA_GD'; } -- cgit v1.2.1 From 31781adf0ca9880069c8831177b34d573456f5d4 Mon Sep 17 00:00:00 2001 From: Oleg Pudeyev Date: Mon, 29 Oct 2012 14:57:27 -0400 Subject: [ticket/11159] static public is the currently approved order. PHPBB3-11159 --- phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php') diff --git a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php index 6c1f3bf00b..1a3523567e 100644 --- a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php +++ b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php @@ -49,7 +49,7 @@ class phpbb_captcha_gd extends phpbb_default_captcha } } - public static function get_instance() + static public function get_instance() { $instance = new phpbb_captcha_gd(); return $instance; -- cgit v1.2.1