PHPackages                             developerarts/nomad\_mimemail - 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. developerarts/nomad\_mimemail

ActiveLibrary

developerarts/nomad\_mimemail
=============================

Nomad MIME Mail, is a PHP class for handling and sending mail MIME type, with support for the dispatch by SMTP and SMTP Auth

168PHP

Since Aug 28Pushed 12y ago1 watchersCompare

[ Source](https://github.com/zyuhel/nomad_mimemail)[ Packagist](https://packagist.org/packages/developerarts/nomad_mimemail)[ RSS](/packages/developerarts-nomad-mimemail/feed)WikiDiscussions master Synced 2d ago

READMEChangelogDependenciesVersions (1)Used By (0)

Nomad MIME Mail
===============

[](#nomad-mime-mail)

Description.
------------

[](#description)

Nomad MIME Mail, is a PHP class for handling and sending mail MIME type, with support for the dispatch by SMTP and SMTP Auth

Currently, this class supports:

- Plain Text
- HTML
- Plain Text with Attachments
- HTML with Attachments
- HTML with Embedded Images
- HTML with Attachments and Embedded Images

It also supports multiple e-mail addresses for sending (to), with a copy (cc) and with a blind carbon copy (bcc), as well as several images embedded in HTML and various attachments

Quick Reference.
----------------

[](#quick-reference)

Attached to this class and documentation is a file called 'nomad\_mimemail.test.php' where is a script with an example of sending mail with text, HTML, Image and Deputy Embedded sent via SMTP. .

To use MIME Mail Nomad is necessary to declare the object as follows:

```
include ('nomad_mimemail.inc.php');
$mimemail = new nomad_mimemail();
```

### Plain Text.

[](#plain-text)

Normally this is how the function 'mail ()' would operate. PHP, however in this version is created so a little different because it sent the body of the message headers and MIME type

```
$mimemail->set_from("me@mail.com");
$mimemail->set_to("friend@mail.com");
$mimemail->set_subject("Nomad MIME Mail: Plain Text");
$mimemail->set_text("This is a MIME Mail with:\n\n- Plain Text");

if ($mimemail->send()) {
    echo "The MIME Mail has been sent";
} else {
    echo "An error has occurred, mail was not sent";
}
```

### Plain Text and HTML.

[](#plain-text-and-html)

Example of sending mail with text and HTML

```
$mimemail->set_from("me@mail.com");
$mimemail->set_to("friend@mail.com");
$mimemail->set_subject("Nomad MIME Mail: Plain Text + HTML");
$mimemail->set_text("This is a MIME Mail with:\n\n- Plain Text\n- HTML");
$mimemail->set_html("This is a MIME Mail with:- Plain Text- HTML");

if ($mimemail->send()) {
    echo "The MIME Mail has been sent";
} else {
    echo "An error has occurred, mail was not sent";
}
```

### Plain Text with Attachments.

[](#plain-text-with-attachments)

Example of creating an email with an attachment and Plain Text. You can do more than adding attachments with the 'add\_attachment' method. For more information, check the function reference guide.

```
$mimemail->set_from("me@mail.com");
$mimemail->set_to("friend@mail.com");
$mimemail->set_subject("Nomad MIME Mail: Plain Text + Attachment");
$mimemail->set_text("This is a MIME Mail with:\n\n- Plain Text\n- Attachment");
$mimemail->add_attachment("test_attachment.tar.gz", "file.tar.gz");

if ($mimemail->send()) {
    echo "The MIME Mail has been sent";
} else {
    echo "An error has occurred, mail was not sent";
}
```

### Plain Text and HTML with Attachments

[](#plain-text-and-html-with-attachments)

Example to create an email with Plain Text, HTML and a deputy. You can add more than one attachment using the 'add\_attachment'.

```
$mimemail->set_from("me@mail.com");
$mimemail->set_to("friend@mail.com");
$mimemail->set_subject("Nomad MIME Mail: Plain Text + HTML + Attachment");
$mimemail->set_text("This is a MIME Mail with:\n\n- Plain Text\n- HTML\n- Attachment");
$mimemail->set_html("This is a MIME Mail with:- Plain Text- HTML- Attachment");
$mimemail->add_attachment("test_attachment.tar.gz", "file.tar.gz");

if ($mimemail->send()) {
    echo "The MIME Mail has been sent";
} else {
    echo "An error has occurred, mail was not sent";
}
```

### Plain Text and HTML with Embedded Images

[](#plain-text-and-html-with-embedded-images)

Example of creating an email with HTML, plain text and an Embedded Image. For the image embedded function, the attachment must have the same name as indicated on the tag 'IMG' HTML message.

```
$mimemail->set_from("me@mail.com");
$mimemail->set_to("friend@mail.com");
$mimemail->set_subject("Nomad MIME Mail: Plain Text + HTML + Embedded Image");
$mimemail->set_text("This is a MIME Mail with:\n\n- Plain Text\n- HTML\n- Embedded Image");
$mimemail->set_html("This is a MIME Mail with:- Plain Text- HTML- Embedded Image");
$mimemail->add_attachment("test_image.gif", "image.gif");

if ($mimemail->send()) {
    echo "The MIME Mail has been sent";
} else {
    echo "An error has occurred, mail was not sent";
}
```

### Plain Text and HTML with Embedded Image and Attachments

[](#plain-text-and-html-with-embedded-image-and-attachments)

Example of creating an email with HTML, plain text, an embedded image and an attachment. For the embedded image to work, the attachment archive must have the same name as indicated on the tag 'IMG'

```
$mimemail->set_from("me@mail.com");
$mimemail->set_to("friend@mail.com");
$mimemail->set_subject("Nomad MIME Mail: Plain Text + HTML + Embedded Image + Attachment");
$mimemail->set_text("This is a MIME Mail with:\n\n- Plain Text\n- HTML\n- Embedded Image\n- Attachment");
$mimemail->set_html("This is a MIME Mail with:- Plain Text- HTML- Embedded Image- Attachment");
$mimemail->add_attachment("test_image", "image.gif");
$mimemail->add_attachment("test_attachment.tar.gz", "file.tar.gz");

if ($mimemail->send()) {
    echo "The MIME Mail has been sent";
} else {
    echo "An error has occurred, mail was not sent";
}
```

### Sending Authenticated SMTP

[](#sending-authenticated-smtp)

To send mail via SMTP it is necessary to call the 'set\_smtp\_host' method and to send mail using SMTP authentication it is necessary to use the 'set\_smtp\_auth' method.

```
$mimemail->set_from("me@mail.com");
$mimemail->set_to("friend@mail.com");
$mimemail->set_subject("Nomad MIME Mail: HTML + Auth SMTP");
$mimemail->set_html("This is a MIME Mail with:- Plain Text- HTML");

$mimemail->set_smtp_host("domain.com");
$mimemail->set_smtp_auth("user", "pass");

if ($mimemail->send()) {
    echo "The MIME Mail has been sent";
} else {
    echo "An error has occurred, mail was not sent";
}
```

At the moment this version is in testing and would appreciate any assistance possible to support such a large amount of SMTP's. If you have a mistake is possible to review the entire conversation that makes this script with SMTP. to do so before the 'send' call to the function 'set\_smtp\_log' a true, and the verdict can bring everything through 'get\_smtp\_log' as illustrated below:

```
$mimemail->set_smtp_log(true);

if ($mimemail->send()) {
    echo "The MIME Mail has been sent";
} else {
    echo $mimemail->get_smtp_log();
}
```

If so, I ask you to leave your report in The Forum where this kind of try to adapt as much as possible the response received from SMTP.

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 60% 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/ed4a99285c65e55ed147f7a2ef366455fc39fa71812944306609637f233389e8?d=identicon)[zyuhel](/maintainers/zyuhel)

---

Top Contributors

[![developarts](https://avatars.githubusercontent.com/u/3060193?v=4)](https://github.com/developarts "developarts (6 commits)")[![zyuhel](https://avatars.githubusercontent.com/u/4603624?v=4)](https://github.com/zyuhel "zyuhel (4 commits)")

### Embed Badge

![Health badge](/badges/developerarts-nomad-mimemail/health.svg)

```
[![Health](https://phpackages.com/badges/developerarts-nomad-mimemail/health.svg)](https://phpackages.com/packages/developerarts-nomad-mimemail)
```

PHPackages © 2026

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