tereta / email
1.0.8
2026-04-28 18:58 UTC
Requires
- php: >=8.4
- tereta/core: ^1.0
- tereta/di: ^1.0
README
π Π ΡΡΡΠΊΠΈΠΉ | English
Overview
Email sending module. Supports SMTP and PHP's built-in mail() function.
Transports
- SMTP β sending via SMTP server with TLS/SSL support
- mail() β built-in PHP function (fallback)
Configuration
SMTP is configured in .config.php:
->set('smtp', Value::factory()->create()
->set('host', 'smtp.gmail.com')
->set('username', 'user@gmail.com')
->set('password', 'password')
->set('from', 'user@gmail.com'))
Usage
use Tereta\Email\Factories\Sender as EmailFactory;
$email = EmailFactory::singleton()->create();
$email->send('recipient@example.com', 'Subject', '<p>Email body</p>');
Headers are automatically checked for injection attacks. Addresses are validated per RFC.
Author and License
Author: Tereta Alexander
Website: tereta.dev
License: Apache License 2.0. See LICENSE.
www.ββββββββββββββββββββββββ βββββββββββββββββ ββββββ
ββββββββββββββββββββββββββββββββββββββββββββββββββ
βββ ββββββ ββββββββββββββ βββ ββββββββ
βββ ββββββ ββββββββββββββ βββ ββββββββ
βββ βββββββββββ βββββββββββ βββ βββ βββ
βββ βββββββββββ βββββββββββ βββ βββ βββ
.dev
Copyright (c) 2024-2026 Tereta Alexander