It seems there is abundant information available on those must have Drupal modules. Numerous developers have shared their top 10 lists, yet there seems to be little variety in their selections. This makes sense, as there are many tried-and-true contributed modules out there that are hard to live without. But what about those modules that achieve a very specific goal? The kind you would only look for when the need arose?
In Q College’s Practical Skills Web Development program, students create Drupal websites for NGO clients to fine tune their skills and better develop their understanding of the client/developer dynamic. Through this process, we have encountered many specific requirements which have led to working with some interesting modules. Each month, I will be walking you through some of those modules that you may not have been aware of, but will be glad to know exist.
Specific need: making a list of PDFs interesting
A client needed to have their entire collection of annual reports available for download as PDF for funders and members. As you can imagine, this made for a rather uninteresting page, basically a very long list of links. With a bit of research, the student working on this project stumbled across PDF to ImageField.
The PDF to ImageField module automatically generates a snapshot image as you upload the .pdf. It can be limited to a single image of the front page of the document or used to generate a gallery of images by creating a snapshot of each page. The configuration is fairly easy to follow:
- Add an imagefield to the content type
- Set the number of values to 1 to create a snapshot of the cover page alone, or ‘unlimited’ if you want snapshots to be generated for each page
- Add a filefield to your content type and select ‘PDF to Image‘ as the widget. Configure this filefield to accept only .pdf file types.
- Configure this field to link the uploaded file field with the target image field
- Configure the display of the rendered image under manage display in the same way you would any image field
The result is a node that is visually more appealing, and when nodes are displayed in a View, it enables the user to accurately select the correct file to download at a glance.
Know any other interesting Drupal modules, or have a specific problem you need to find a good module for? Let us know in the comments!