Skip to content

Create images from one-or-more pages of a PDF file.

License

Notifications You must be signed in to change notification settings

a8w4/pdf_to_image

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PDF to Image

PDF to Image create images from PDF files automatically. This is useful if you'd like to display a preview of the first page of your uploaded PDF, or showcase a gallery of all the pages in a PDF file.

This module utilizes the Imagick PHP extension for the processing of PDF files to images, and is inspired by (but not a direct port of) Drupal's PDF to ImageField module.

Installation

  • Make sure the Imagick PHP extension is installed on your server.

    On a Debian-based system, this is as simple as running: sudo apt-get install imagemagick php5-imagick.
    Note that support for installing Imagick is not provided by this module or its maintainer(s).

  • Install this module using the official Backdrop CMS instructions at https://backdropcms.org/guide/modules.

  • Add an Image field to your entity to store the generated image(s). Make sure the image format you wish to use is in the 'Allowed file extensions' setting. Set the 'Number of values' to the maximum number of pages you wish to store (note that this may end up being less, depending how many pages the PDF has).

  • Add a File field to your entity and set the widget type to 'File'. Select the image field you added above in the 'Image field' setting, then configure the other settings to your preference. Make sure 'pdf' is added to the 'Allowed file extensions' setting.
    Note that you can set the 'Number of values' of the file field to whatever you like, but only the first file uploaded will be processed by this module.

  • Create an entity, upload a PDF file, and the image(s) will be generated on save.

Issues

Bugs and Feature requests should be reported in the Issue Queue: https://github.com/backdrop-contrib/pdf_to_image/issues.

Current Maintainers

Credits

License

This project is GPL v2 software. See the LICENSE.txt file in this directory for complete text.

About

Create images from one-or-more pages of a PDF file.

Resources

License

Stars

Watchers

Forks

Packages

No packages published