PHPackages                             voronkovich/phpmailer-dsn - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. voronkovich/phpmailer-dsn

Abandoned → [phpmailer/phpmailer](/?search=phpmailer%2Fphpmailer)ArchivedLibrary[Utility &amp; Helpers](/categories/utility)

voronkovich/phpmailer-dsn
=========================

Library for configuring PHPMailer with DSN string

v0.0.1(3y ago)0120MITPHP

Since Feb 27Pushed 3y ago1 watchersCompare

[ Source](https://github.com/voronkovich/phpmailer-dsn)[ Packagist](https://packagist.org/packages/voronkovich/phpmailer-dsn)[ Fund](https://ko-fi.com/voronkovich)[ RSS](/packages/voronkovich-phpmailer-dsn/feed)WikiDiscussions main Synced yesterday

READMEChangelog (1)Dependencies (1)Versions (2)Used By (0)

phpmailer-dsn
=============

[](#phpmailer-dsn)

[![CI](https://github.com/voronkovich/phpmailer-dsn/actions/workflows/ci.yml/badge.svg)](https://github.com/voronkovich/phpmailer-dsn/actions/workflows/ci.yml)

Library for configuring [PHPMailer](https://github.com/PHPMailer/PHPMailer) with [DSN string](https://en.wikipedia.org/wiki/Data_source_name).

Abandoned!!!
============

[](#abandoned)

This feature [was merged to PHPMailer](https://github.com/PHPMailer/PHPMailer/pull/2874). Use the PHPMailer itself instead:

```
composer require phpmailer/phpmailer:^6.8.0
```

Installation
------------

[](#installation)

```
composer require voronkovich/phpmailer-dsn
```

Usage
-----

[](#usage)

```
use Voronkovich\PHPMailerDSN\DSNConfigurator;
use PHPMailer\PHPMailer\PHPMailer;

$mailer = new PHPMailer(true);
$configurator = new DSNConfigurator();

$configurator->configure($mailer, 'smtp://localhost:2525');
```

Configuraton
------------

[](#configuraton)

Supported protocols:

- `mail`
- `sendmail`
- `qmail`
- `smtp`
- `smtps`

Additional configuration could be applied via query string:

```
$dsn = 'mail://localhost?XMailer=SuperMailer&FromName=CoolSite';

$configurator->configure($mailer, $dsn);
```

[PHPMailer](https://github.com/PHPMailer/PHPMailer) is configured by public properties, so you can use any of them. All allowed options could be found at [PHPMailer Docs](https://phpmailer.github.io/PHPMailer/classes/PHPMailer-PHPMailer-PHPMailer.html#toc-properties).

Examples
--------

[](#examples)

### Sendmail

[](#sendmail)

```
$dsn = 'sendmail://localhost?Sendmail=/usr/sbin/sendmail%20-oi%20-t';

$configurator->configure($mailer, $dsn);
```

### SMTP

[](#smtp)

```
$dsn = 'smtp://user@password@localhost?SMTPDebug=3&Timeout=1000';

$configurator->configure($mailer, $dsn);
```

### Gmail

[](#gmail)

```
$dsn = 'smtps://user@gmail.com:password@smtp.gmail.com?SMTPDebug=3';

$configurator->configure($mailer, $dsn);
```

License
-------

[](#license)

Copyright (c) Voronkovich Oleg. Distributed under the MIT.

###  Health Score

20

—

LowBetter than 13% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity35

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

1223d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/2299535?v=4)[Oleg Voronkovich](/maintainers/voronkovich)[@voronkovich](https://github.com/voronkovich)

---

Top Contributors

[![voronkovich](https://avatars.githubusercontent.com/u/2299535?v=4)](https://github.com/voronkovich "voronkovich (6 commits)")

### Embed Badge

![Health badge](/badges/voronkovich-phpmailer-dsn/health.svg)

```
[![Health](https://phpackages.com/badges/voronkovich-phpmailer-dsn/health.svg)](https://phpackages.com/packages/voronkovich-phpmailer-dsn)
```

###  Alternatives

[creagia/filament-code-field

A Filamentphp input field to edit or view code data.

57307.1k3](/packages/creagia-filament-code-field)[element119/module-indexer-deploy-config

A Magento 2 module that allows developers to lock indexer modes via deployment config.

35151.9k](/packages/element119-module-indexer-deploy-config)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
