Author: Nikita Popov (nikic)
Date: 2021-08-26T14:22:04+02:00
Commit:
https://github.com/php/web-bugs/commit/f259231094cc03c490903e55d8b40ad4db96621f
Raw diff:
https://github.com/php/web-bugs/commit/f259231094cc03c490903e55d8b40ad4db96621f.diff
Count https:// URLs towards spam
Changed paths:
M include/functions.php
Diff:
diff --git a/include/functions.php b/include/functions.php
index f52f5c7d..7c4841a1 100644
--- a/include/functions.php
+++ b/include/functions.php
@@ -195,7 +195,9 @@ function is_spam($string)
return false;
}
- if (substr_count(strtolower($string), 'http://') > 5) {
+ $count = substr_count(strtolower($string), 'http://')
+ + substr_count(strtolower($string), 'https://');
+ if ($count > 5) {
return true;
}
--
PHP Webmaster List Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php