定制 dachcom-digital/emailizr 二次开发

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

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

dachcom-digital/emailizr

Composer 安装命令:

composer require dachcom-digital/emailizr

包简介

Pimcore Emailizr - create html emails the right way!

README 文档

README

Important

This bundle will not be compatible with Pimcore 12 or any future Pimcore versions.

For all future development, updates, and documentation, please refer to opendxp.io:

Note: We are open to partnerships for those interested in porting this bundle to future versions.

For inquiries, please contact: dcdi@dachcom.ch

Software License Software License Latest Release Tests PhpStan

Requirements

  • Pimcore ^11.4
  • PHP >= 8.1
  • Twig >= 3.9

Release Plan

Release Supported Pimcore Versions Supported Symfony Versions Release Date Maintained Branch
>=3.1 11.4 ^6.4 08.01.2025 Feature Branch master
3.x 11.0 ^6.2 30.08.2023 Feature Branch master
2.x 10.1 - 10.6 ^5.4 21.09.2021 No 2.x
1.x 6.0 - 6.9 3.4, ^4.4 06.12.2017 No 1.x

Installation

"require" : {
    "dachcom-digital/emailizr" : "~3.2.0",
}

Add Bundle to bundles.php:

return [
    EmailizrBundle\EmailizrBundle::class => ['all' => true],
];
  • Create valid email markup with inky and inline styles.
  • Respect editables in pimcore edit mode.

Usage

Just extend the emailizr layout:

{% extends '@Emailizr/layout.html.twig' %}

This will include a markup like this. You may want to change it:

{% apply spaceless %}
{{ emailizr_style_collector.add('@EmailizrBundle/public/css/foundation-for-emails/foundation.min.css') }}
{% emailizr_inline_style %}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="viewport" content="width=device-width"/>
    {% block headStyles %}
        <style type="text/css">
            {% autoescape false %}
                {{ emailizr_inline_style(emailizr_style_collector) }}
            {% endautoescape %}
        </style>
    {% endblock %}
</head>
{% apply inky_to_html %}
    <body>
        {% block body %}
            <table class="body">
                <tr>
                    <td class="center" align="center" valign="top">
                        <center>
                            {% block content %}
                            {% endblock %}
                        </center>
                    </td>
                </tr>
            </table>
            <!-- prevent Gmail on iOS font size manipulation -->
            <div style="display:none; white-space:nowrap; font:15px courier; line-height:0;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </div>
        {% endblock %}
        </body>
{% endapply %}
</html>
{% end_emailizr_inline_style %}
{% endapply %}

Service

If you need to parse values in a custom context, you may use the ContentService.

<?php

use EmailizrBundle\Service\ContentService;

class YourClass
{
    public function __construct(protected ContentService $contentService)
    {
    }

    public function parse($content)
    {
        $cssFile = PIMCORE_WEB_ROOT . '/static/css/email.css';

        return $this->contentService->checkContent($content, $cssFile, FALSE, TRUE, TRUE);
    }
}

Further Information

Upgrade Info

Before updating, please check our upgrade notes!

License

DACHCOM.DIGITAL AG, Löwenhofstrasse 15, 9424 Rheineck, Schweiz
dachcom.com, dcdi@dachcom.ch
Copyright © 2025 DACHCOM.DIGITAL. All rights reserved.

For licensing details please visit LICENSE.md

dachcom-digital/emailizr 适用场景与选型建议

dachcom-digital/emailizr 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 378.69k 次下载、GitHub Stars 达 16, 最近一次更新时间为 2017 年 09 月 01 日, 在 PHP 生态内属于活跃度较高的组件。

它主要适用于以下技术方向: 「email」 「pimcore」 「inky」 「inline style」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。

我们在过去多个企业项目中使用过 dachcom-digital/emailizr 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 dachcom-digital/emailizr 我们能提供哪些服务?
定制开发 / 二次开发

基于 dachcom-digital/emailizr 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

  • 总下载量: 378.69k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 17
  • 点击次数: 31
  • 依赖项目数: 3
  • 推荐数: 0

GitHub 信息

  • Stars: 16
  • Watchers: 10
  • Forks: 5
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-3.0-or-later
  • 更新时间: 2017-09-01