<?php
/**
- * @copyright Copyright (C) 2020, Friendica
+ * @copyright Copyright (C) 2010-2021, the Friendica project
*
* @license GNU AGPL version 3 or any later version
*
$recipient = trim($recipient);
if (!filter_var($recipient, FILTER_VALIDATE_EMAIL)) {
- notice(DI::l10n()->t('%s : Not a valid email address.', $recipient) . EOL);
+ notice(DI::l10n()->t('%s : Not a valid email address.', $recipient));
continue;
}
$nmessage = $message;
}
- $additional_headers = 'From: ' . $app->user['email'] . "\n"
- . 'Sender: ' . DI::emailer()->getSiteEmailAddress() . "\n"
+ $additional_headers = 'From: "' . $app->user['email'] . '" <' . DI::emailer()->getSiteEmailAddress() . ">\n"
. 'Content-type: text/plain; charset=UTF-8' . "\n"
. 'Content-transfer-encoding: 8bit';
$current_invites++;
DI::pConfig()->set(local_user(), 'system', 'sent_invites', $current_invites);
if ($current_invites > $max_invites) {
- notice(DI::l10n()->t('Invitation limit exceeded. Please contact your site administrator.') . EOL);
+ notice(DI::l10n()->t('Invitation limit exceeded. Please contact your site administrator.'));
return;
}
} else {
- notice(DI::l10n()->t('%s : Message delivery failed.', $recipient) . EOL);
+ notice(DI::l10n()->t('%s : Message delivery failed.', $recipient));
}
}
- notice(DI::l10n()->tt('%d message sent.', '%d messages sent.', $total) . EOL);
+ info(DI::l10n()->tt('%d message sent.', '%d messages sent.', $total));
}
public static function content(array $parameters = [])