PHPackages                             voceconnect/voce-post-pdfs - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [PDF &amp; Document Generation](/categories/documents)
4. /
5. voceconnect/voce-post-pdfs

ActiveWordpress-plugin[PDF &amp; Document Generation](/categories/documents)

voceconnect/voce-post-pdfs
==========================

Generates PDF's from Posts

2.1(4y ago)45802[1 PRs](https://github.com/voceconnect/voce-post-pdfs/pulls)GPL-2.0-or-laterPHP

Since Apr 2Pushed 3y ago12 watchersCompare

[ Source](https://github.com/voceconnect/voce-post-pdfs)[ Packagist](https://packagist.org/packages/voceconnect/voce-post-pdfs)[ RSS](/packages/voceconnect-voce-post-pdfs/feed)WikiDiscussions master Synced today

READMEChangelog (7)Dependencies (1)Versions (11)Used By (0)

Voce Post PDFs
==============

[](#voce-post-pdfs)

Contributors: johnciacia, kevinlangleyjr, brockangelo
Tags: printing, pdf
Requires at least: 3.2
Tested up to: 3.8.3
Stable tag: 1.2.3
License: GPLv2 or later
License URI:

A WordPress plugin/module that generates a pdf from a post.

Description
-----------

[](#description)

This plugin generates a PDF file from a post's content using the PHP dompdf library. Simply link to the post + '/pdf/' and a PDF will be generated. You have the ability to customize the upload path, the PDF template that is used, and the filename format through filters.

Installation
------------

[](#installation)

### As standard plugin:

[](#as-standard-plugin)

> See [Installing Plugins](http://codex.wordpress.org/Managing_Plugins#Installing_Plugins).

### As theme or plugin dependency:

[](#as-theme-or-plugin-dependency)

> After dropping the plugin into the containing theme or plugin, add the following:

```
if( ! class_exists( 'Voce_Post_PDFS' ) ) {
	require_once( $path_to_vpp . '/voce-post-pdfs.php' );
}
```

Usage
-----

[](#usage)

Add a Download PDF link to `/pdf/`:

```
$pdf_link = esc_url( trailingslashit( get_permalink() ) . 'pdf/' );
```

### Customize with filters

[](#customize-with-filters)

**To modify the logo used in the PDF header:**

```
add_action( 'voce_post_pdfs_logo', function(){
  do_action('newsroom_custom_header_logo');
});
```

**Use your own template for the PDF, relative to the theme directory:**

```
add_filter('voce_post_pdf_print_template', function($template){
  return 'print.php';
});
```

**Modify query args:**

```
add_filter('voce_post_pdfs_save_query_args', function($args){
  if( isset( $_GET['lang'] ) )
     $args['lang'] = $_GET['lang'];
  return $args;
});
```

**Modify the default filename format (defaults to post-title.pdf):**

```
add_filter('voce_post_pdfs_save_filename', function($filename) {
  $lang = ( isset( $_GET['lang'] )  ? '-' . sanitize_key( $_GET['lang'] ) : '');
  $filename = basename($filename, '.pdf');
  return $filename . $lang . '.pdf';
});
```

**Modify the upload location on the server:**

```
add_filter('voce_post_pdfs_upload_basepath', function($basepath, $post){
  $uploads = wp_upload_dir();
  $basepath = $uploads['basedir'] . '/' . date('Y', strtotime($post->post_date) ) . '/' . date('m', strtotime($post->post_date) ) . '/pdf/';
  return $basepath;
}, 10, 2);
```

**Modify the url to the pdf:**

```
add_filter('voce_post_pdfs_upload_baseurl', function($baseurl, $post){
  $uploads = wp_upload_dir();
  $baseurl = $uploads['baseurl'] . '/' . date('Y', strtotime($post->post_date) ) . '/' . date('m', strtotime($post->post_date) ) . '/pdf/';
  return $baseurl;
}, 10, 2);
```

Changelog
=========

[](#changelog)

**1.2.3**

- Reducing calls to wp\_uploads\_dir for performance reasons

**1.2.1**
*Reorganizing the path declarations and pdf existance check in `save_post` to improve performace.*

**1.2**
*Adding a parameter to `save_pdf` to not overwrite the PDF, if the PDF already exists. `get_upload_basepath` and `get_upload_baseurl` are now public, so other plugins can retrieve a PDF's location.*

###  Health Score

34

—

LowBetter than 77% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity19

Limited adoption so far

Community19

Small or concentrated contributor base

Maturity69

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~405 days

Recently: every ~701 days

Total

8

Last Release

1579d ago

Major Versions

1.2.3 → 2.02021-06-02

### Community

Maintainers

![](https://www.gravatar.com/avatar/2f9c70d57401b4844db2d0391e4a17919cd1faa95181099c156e6586798b4b98?d=identicon)[kevinlangleyjr](/maintainers/kevinlangleyjr)

![](https://www.gravatar.com/avatar/60c26d865c2615b90378cd9d45d70e3d11f58de984e6831a125ec22672c1d390?d=identicon)[voceconnect](/maintainers/voceconnect)

---

Top Contributors

[![brock](https://avatars.githubusercontent.com/u/654725?v=4)](https://github.com/brock "brock (9 commits)")[![kevinlangleyjr](https://avatars.githubusercontent.com/u/877634?v=4)](https://github.com/kevinlangleyjr "kevinlangleyjr (8 commits)")[![goldenapples](https://avatars.githubusercontent.com/u/665992?v=4)](https://github.com/goldenapples "goldenapples (7 commits)")[![joehoyle](https://avatars.githubusercontent.com/u/161683?v=4)](https://github.com/joehoyle "joehoyle (1 commits)")[![smccafferty](https://avatars.githubusercontent.com/u/641462?v=4)](https://github.com/smccafferty "smccafferty (1 commits)")

### Embed Badge

![Health badge](/badges/voceconnect-voce-post-pdfs/health.svg)

```
[![Health](https://phpackages.com/badges/voceconnect-voce-post-pdfs/health.svg)](https://phpackages.com/packages/voceconnect-voce-post-pdfs)
```

###  Alternatives

[barryvdh/laravel-dompdf

A DOMPDF Wrapper for Laravel

7.3k87.6M274](/packages/barryvdh-laravel-dompdf)[consoletvs/invoices

Generate PDF invoices for your customers in laravel

455275.5k](/packages/consoletvs-invoices)[nucleos/dompdf-bundle

This bundle provides a wrapper for using dompdf inside symfony.

54882.8k1](/packages/nucleos-dompdf-bundle)[dino/dompdf-module

A Zend Framework 2 module for incorporating DOMPDF support.

61465.1k8](/packages/dino-dompdf-module)[omaralalwi/gpdf

Custom PDF wrapper supporting Arabic language

15411.6k](/packages/omaralalwi-gpdf)[phpnt/yii2-export

Yii2 It saves data in xls, csv, word, html, pdf files.

158.9k](/packages/phpnt-yii2-export)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
