PHPackages                             jiangshengxin/email - 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. [Mail &amp; Notifications](/categories/mail)
4. /
5. jiangshengxin/email

Abandoned → [symfony/mailer](/?search=symfony%2Fmailer)Library[Mail &amp; Notifications](/categories/mail)

jiangshengxin/email
===================

JiangShengXin PHPEmail

20211210(6y ago)0516MITPHP

Since May 11Pushed 4y agoCompare

[ Source](https://github.com/jiangshengxin/php-email)[ Packagist](https://packagist.org/packages/jiangshengxin/email)[ RSS](/packages/jiangshengxin-email/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)DependenciesVersions (2)Used By (0)

php-email
=========

[](#php-email)

PHPEmail邮箱类

### 安装

[](#安装)

```
composer require "jiangshengxin/email"

```

### 使用查看 demo.php

[](#使用查看-demophp)

```
$mail = new \PHPMailer\PHPMailer();
        /*服务器相关信息*/
        $mail->IsSMTP();                 //设置使用SMTP服务器发送
        $mail->SMTPAuth = true;               //开启SMTP认证
        $mail->Host = 'smtp.163.com';        //设置 SMTP 服务器,自己注册邮箱服务器地址
        $mail->Username = 'jiangshengxin@163.com';  //发信人的邮箱名称
        $mail->Password = 'xxxxxxx';    //发信人的邮箱密码
        /*内容信息*/
        $mail->IsHTML(true);              //指定邮件格式为：html 不加true默认为以text的方式进行解析
        $mail->CharSet = "UTF-8";                 //编码
        $mail->From = 'jiangshengxin@163.com';             //发件人完整的邮箱名称
        $mail->SMTPSecure = 'tls';       //加密方式 "" or "ssl" or "tls"
        $mail->FromName = $user;             //发信人署名
        $mail->Subject = $title;             //信的标题
        $mail->MsgHTML($content);                 //发信主体内容

        if (!empty($fileUrl) && file_exists($fileUrl)) {  //附件
            $mail->AddAttachment($fileUrl);
        }

        //发送邮件 收件人地址
        if (is_array($addRess)) {  //群发 or 单发
            foreach ($addRess as $valRess) {
                $mail->AddAddress($valRess);
            }
        } else {
            $mail->AddAddress($addRess);
        }

        //使用send函数进行发送
        if ($mail->Send()) {
            return true;
        } else {
            //self::$error=$mail->ErrorInfo;
            return $mail->ErrorInfo;
        }
```

**搞定**

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity55

Maturing project, gaining track record

 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

2190d ago

### Community

Maintainers

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

---

Top Contributors

[![sxin0](https://avatars.githubusercontent.com/u/29392026?v=4)](https://github.com/sxin0 "sxin0 (3 commits)")

### Embed Badge

![Health badge](/badges/jiangshengxin-email/health.svg)

```
[![Health](https://phpackages.com/badges/jiangshengxin-email/health.svg)](https://phpackages.com/packages/jiangshengxin-email)
```

###  Alternatives

[tijsverkoyen/css-to-inline-styles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

5.8k505.3M228](/packages/tijsverkoyen-css-to-inline-styles)[minishlink/web-push

Web Push library for PHP

1.9k12.0M53](/packages/minishlink-web-push)[laravel-notification-channels/twilio

Provides Twilio notification channel for Laravel

2587.7M12](/packages/laravel-notification-channels-twilio)[spatie/url-signer

Generate a url with an expiration date and signature to prevent unauthorized access

4422.3M16](/packages/spatie-url-signer)[mattketmo/email-checker

Throwaway email detection library

2742.0M5](/packages/mattketmo-email-checker)[laravel-notification-channels/discord

Laravel notification driver for Discord.

2371.3M11](/packages/laravel-notification-channels-discord)

PHPackages © 2026

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