icircle/docx-template-in-php
最新稳定版本:v0.1.3
Composer 安装命令:
composer require icircle/docx-template-in-php
包简介
Create Templates in MS Word docx format and use them Creating Business documents using PHP
README 文档
README
Create Templates in MS Word docx format and use them Creating Business documents using PHP
What's New
Changed the namespace of DocxTemplate from default to icircle\Template\Docx
Introduction
This library merges the data in php array into docx file.
The template docx file can be created in MS Word, To specify keys use [key] format in MS Word (i.e, specify the array indices inside the square bracket)
Example
for the data
{
"host":{
"name":"Host Company",
"address":"1st Main, 2nd Cross, Bangalore"
}
}
the possible keys are [host.name] [host.address]
Basic Usage
use icircle\Template\Docx\DocxTemplate; $docxTemplate = new DocxTemplate('path/to/template/file'); $dataArray = array() // fill the $dataArray with data $docxTemplate->merge($dataArray,'path/to/output/file');
For More Usage please see the included tests or contact me
统计信息
- 总下载量: 22.66k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 44
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: Apache
- 更新时间: 2015-07-16