承接 jitendra/breezy-pdf-lite-php 相关项目开发

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

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

jitendra/breezy-pdf-lite-php

Composer 安装命令:

composer require jitendra/breezy-pdf-lite-php

包简介

Php client for breezy-pdf-lite, an HTML -> PDF service powered by Google Chrome (breezypdf.com)

README 文档

README

Php client for breezy-pdf-lite, an HTML -> PDF service powered by Google Chrome.

Dependencies

Installation

composer require jitendra/breezy-pdf-lite-php

Usage & Examples

use BreezyPdfLite\BreezyPdfLite;

$breezy = new BreezyPdfLite('http://localhost:5000', 'VERY_RANDOM_SECRET');

// Gets pdf string for given html content
$breezy->readHtml('<h1>Hello, world!</h1>')
       ->getPdfAsString();

// Saves converted pdf file locally for given html content
$breezy->readHtml('<h1>Hello, world!</h1>')
       ->getPdfSavedAs('/home/ubuntu/hello.pdf');

// Saves converted pdf file locally for given local html/view file
$breezy->readHtmlFromFile('/home/ubuntu/hello.html')
       ->getPdfSavedAs('/home/ubuntu/hello.pdf');

// Saves converted pdf file locally for given remote html page/view
$breezy->readHtmlFromRemote('https://example.com')
       ->getPdfSavedAs('/home/ubuntu/example.pdf');

// Saves converted pdf file locally for given local html page/view
// Also accepts additional print options, ref https://github.com/jitendra-1217/breezy-pdf-lite-php/blob/master/src/Options.php for all available options
// Please note that these options can be provided as part of html meta tags from the html page/view itself (as in /example/2.php file)
// Following options are actually appended in html content as meta tags
$breezy->withOptions(['height' => 5, 'width' => 5])
       ->readHtmlFromFile(__DIR__.'/input/example.html')
       ->getPdfSavedAs(__DIR__.'/output/example.pdf');

Additionally, refer to /examples/* folder for quick start & experiment with options etc.

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: Unknown
  • 更新时间: 2018-07-08

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固