How to Display WordPress Protected PDF Files in Lightbox

In this article, we will show you how to display PDF files protected by Watermark WordPress Files in the lightbox using the top WordPress popup plugins:

Step 1: Create a popup containing a protected pdf file

After activating the plugin, go to Popup Maker >> Add Popup to create a new one.

Then insert your protected pdf file into popup content using our shortcode or Protect PDF icon.

You also need to create a new trigger that defines when a popup opens.

 

Step 2: Insert popup into content

Navigate to the content in which you want to display the protected pdf file and edit it. You’re recommended to use Classic Editor.

Click on “Popup Maker Shortcodes” icon to insert your popup.

Once done, click “Publish” or “Update” the content.

The pdf popup will display when users click on the button link as the image below.

Click here to see it in action.

 

Step 1: Create a popup containing protected pdf file

Once activating the plugin, go to Popup Builder >> Add New and select HTML format to create a new popup.

Then insert your protected pdf file into popup content using our shortcode or Protect PDF icon.

Step 2: Insert popup into content

Navigate to the content in which you want to display the protected pdf and edit it. You’re recommended to use Classic Editor.

Click on “Insert popup” button to insert your popup.

Shortcodes Ultimate

With Shortcodes Ultimate plugin, simply add the following sample code into your content.

[su_lightbox type="inline" src="#my-pdf-popup"] Click me to see pdf file [/su_lightbox]

[su_lightbox_content id="#my-pdf-popup"] [pda_pdf_viewer id=888] [/su_lightbox_content]

Don’t forget to change “id” to the actual file id of your protected pdf.

Lasted updated on October 6, 2020