承接 inspiredminds/contao-isotope-pdf-templates 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

inspiredminds/contao-isotope-pdf-templates

最新稳定版本:2.4.0

Composer 安装命令:

composer require inspiredminds/contao-isotope-pdf-templates

包简介

Adds a new document type in Contao Isotope where you can define PDF templates.

README 文档

README

Contao Isotope PDF Templates

Adds a new document type in Contao Isotope where you can define PDF templates.

Important: version 2.x of this extension uses mPDF instead of TCPDF. Here are some things to note:

  • mPDF only supports the following fonts: https://mpdf.github.io/fonts-languages/fonts-in-mpdf-7-x.html.
  • mPDF has superior HTML and CSS capabilities.
  • It is recommended to use a full HTML markup in your iso_document_… template.
  • By default only PDF documents up to PDF version 1.4 are supported by the FPDI PDF-Parser used by mPDF, thus you may need to convert them to this version beforehand. However, you can buy the commercial version in order to be able to convert any PDF.

Screenshot

Custom fonts

Since version 2.1.0 you are able to integrate custom fonts directly via the back end. First you need to upload the TTF files into a directory within /files. Then you need to chose that folder in the font settings of the document. After choosing the correct folder you need to save the settings, then you will be able to configure the discovered font files.

Screenshot

For each font you want to use you need enable it and set the variant and name of the font in lowercase.

Note: mPDF maps certain common font names to its own default fonts. If a font is not working, try setting a more unique font name.

Event

The extension provides a ModifyPdfEvent with which you can access the mPDF Isotope Document instance, in order to change some parameters or add additional variables etc.

// src/EventListener/ModifyPdfEventListener.php
namespace App\EventListener;

use InspiredMinds\ContaoIsotopePdfTemplatesBundle\Event\ModifyPdfEvent;
use Symfony\Component\EventDispatcher\Attribute\AsEventListener;

#[AsEventListener(ModifyPdfEvent::EVENT_NAME)]
class ModifyPdfEventListener
{
    public function __invoke(ModifyPdfEvent $event): void
    {
        // Access the mPDF object instance
        $mpdf = $event->getPdf();

        // Access the Isotope Document instance
        $document = $event->getDocument();
    }
}

统计信息

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

GitHub 信息

  • Stars: 0
  • Watchers: 3
  • Forks: 3
  • 开发语言: PHP

其他信息

  • 授权协议: LGPL-3.0-or-later
  • 更新时间: 2019-05-01

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固