定制 cbowofrivia/dmarc-record-builder 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

cbowofrivia/dmarc-record-builder

最新稳定版本:2.1.0

Composer 安装命令:

composer require cbowofrivia/dmarc-record-builder

包简介

A lean package that makes creating DMARC records user friendly

README 文档

README

Latest Version on Packagist Tests Total Downloads

Installation

You can install the package via composer:

composer require cbowofrivia/dmarc-record-builder

Usage

$record = new DmarcRecord();

$record->policy('none')
    ->subdomainPolicy('none')
    ->pct(100)
    ->rua('mailto:example@example.com')
    ->ruf('mailto:example@example.com')
    ->adkim('relaxed')
    ->aspf('relaxed')
    ->reporting('any')
    ->interval(604800);

$record = (string) $record;
// v=DMARC1; p=none; sp=none; pct=100; rua=mailto:example@example.com; ruf=mailto:example@example.com; fo=1; adkim=r; aspf=r; ri=604800;

You can also build the record in the constructor

$record = new DmarcRecord(
    version: 'DMARC1',
    policy: 'none',
    subdomain_policy: 'none',
    pct: 100,
    rua: 'mailto:example@example.com',
    ruf: 'mailto:example@example.com',
    adkim: 'relaxed',
    aspf: 'relaxed',
    reporting: 'any',
    interval: 604800
);

$record = (string) $record;
// v=DMARC1; p=none; sp=none; pct=100; rua=mailto:example@example.com; ruf=mailto:example@example.com; fo=1; adkim=r; aspf=r; ri=604800;

Testing

composer test

Changelog

Please see CHANGELOG for more information on what has changed recently.

Credits

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 115.79k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 4
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 4
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2022-05-06