Tools to Capture and Convert the Web
GrabzIt Save As PDF Plugin

How to use the Save As PDF Plugin

The Save As PDF Plugin Plugin adds the ability to save any web page as PDF on any website, CMS or blog. Such as WordPress, Drupal and Joomla.

Just add the class grabzit-pdf-save to an HTML element such as a link, button or image. Then when the user clicks on the HTML element, the current web page is downloaded in the PDF file format. This allows your users to read a good offline version of your web page at a later date.

To get started place the line below at the bottom of the page just above the closing body tag. Then replace the "APPLICATION KEY" with your actual application key.

new GrabzItSaveAsPDF("Sign in to view your Application Key");

Next, to add the ability to convert a web page to the PDF format, to your web page. Simply add the grabzit-pdf-save class to an HTML element such as a link. This will then be read automatically and whenever someone clicks on the HTML element a download of the web page will be generated.

You do not have to set any other configurations options other than that. However you can specify all of the general and PDF parameters in the options object.

For instance the default filename of the PDF file that will be downloaded when a web page is saved, is the title of the web page. However in the below example we have set the filename of the download to be mypage.pdf instead.

new GrabzItSaveAsPDF("Sign in to view your Application Key", {"filename": "mypage.pdf"});

If you want to download something other than the current page. You can specify a different URL by using the grabzit-url attribute for instance.

<a href="#" grabzit-url="http://www.google.com" class="grabzit-pdf-save">Save as PDF</a>

While you are of course free to alter the JavaScript or CSS as you wish! The Save As PDF Plugin does provide special CSS classes that you can use to style the preview box.

These include the grabzit-pdf-save-progress. This specifies the style of the element with the grabzit-pdf-save class when the PDF is being generated. By default the HTML element appears disabled while GrabzIt creates the PDF. However this can be changed easily.

Installing GrabzIt Save As PDF on a Blog or CMS

GrabzIt's Save As PDF plugin is fully compatible with a blog or CMS. Just open blog-or-cms-install.txt found in the plugin download, this includes all the required JavaScript and CSS in one block. This can then be inserted into a widget that accepts raw HTML.

Such widgets are present in most blog or Content Management Systems. Remember to locate it at the bottom of the page after the content. This will ensure that all HTML elements decorated with the special CSS classes are enabled.

Download Now


This JavaScript plugin is completely open source! If you want to view or improve the source code you can find it on GitHub.
Try all our premium features for free with a 7 day free trial. Then from $5.99 a month, unless cancelled.
  • More Captures
  • More Features
  • More API's
  • Bigger Scrapes
  • Bigger Captures
  • Bigger Everything
Start Free Trial