1
0
mirror of https://github.com/php/web-php.git synced 2026-03-23 23:02:13 +01:00

Enhancement: Enable no_mixed_echo_print fixer (#864)

This commit is contained in:
Andreas Möller
2023-12-06 15:19:57 +01:00
committed by GitHub
parent 9709f819a4
commit a528e6e91b
6 changed files with 12 additions and 11 deletions

View File

@@ -107,11 +107,11 @@ if ($process) {
// If there is any non-header result, then it is an error
if ($result) {
if (strpos($result, '[TOO MANY NOTES]') !== false) {
print "<p class=\"formerror\">As a security precaution, we only allow a certain number of notes to be submitted per minute. At this time, this number has been exceeded. Please re-submit your note in about a minute.</p>";
echo "<p class=\"formerror\">As a security precaution, we only allow a certain number of notes to be submitted per minute. At this time, this number has been exceeded. Please re-submit your note in about a minute.</p>";
} elseif (($pos = strpos($result, '[SPAMMER]')) !== false) {
$ip = trim(substr($result, $pos + 9));
$spam_url = $ip_spam_lookup_url . $ip;
print '<p class="formerror">Your IP is listed in one of the spammers lists we use, which aren\'t controlled by us. More information is available at <a href="' . $spam_url . '">' . $spam_url . '</a>.</p>';
echo '<p class="formerror">Your IP is listed in one of the spammers lists we use, which aren\'t controlled by us. More information is available at <a href="' . $spam_url . '">' . $spam_url . '</a>.</p>';
} elseif (strpos($result, '[SPAM WORD]') !== false) {
echo '<p class="formerror">Your note contains a prohibited (usually SPAM) word. Please remove it and try again.</p>';
} elseif (strpos($result, '[CLOSED]') !== false) {