This is a short tutorial for those wishing to do more with PDFs in DXP 7.0. You are strongly encouraged to read Adding Files to a Document Library first to get a better understanding of how the Documents and Media works.
One thing that all assets have in common is that you can get a URL to each document, image, or video. There are other tutorials, such as Embedding Videos in Web Content Articles and Embedding Videos in Blog Entries that gives you more ideas of what you can do.
For PDFs, the concept is the same. Once you have the URL, there are several things you can do with it.
Resolution
One use case is a company's intranet where the Documents and Media serves as a repository for all important documents. Let's call this company ACME. Now imagine ACME Corp's HR department has several policies and procedures for documents, such as, Health Care Benefits, Whistleblower Protection, USERRA, Investment like 401(k)s and 403(b)s, and so forth. Instead of granting access to the Docs and Media portlet and having the employees try to find the documents, ACME's content managers can do embed PDF's URL as a Link to URL type of Page. When the employees click on each page, it will open the PDF directly in a new browser tab or window. And when the employees are done, clicking Back in the browser will take them back to the platform.
Follow the steps below for a demonstration.
- In the Control Panel → Navigation, click the 3-dot icon → Add Page.
- Create a parent page for the Navigation menu:
- Enter a Name for the page: Important HR Documents.
- Select Page Set from the Type dropdown menu. Doing so allows a page on the Navigation Bar to be placeholder for child pages while not creating any content.
- Click Add Page.
- Next, create a child page that uses a Link to URL Page type.
- Click the 3-dot icon → Add Child Page next to Important HR Documents.
- Enter a Name for the child page: Benefits.
- Enter the PDF's URL. For example,
http://www.alpha.com:8080/documents/77373/0/ACME+Employee+Benefits.pdf/41e37c84-3560-22b5-e972-fe3f970ba062?t=1549495371077
.
- Click Add Page.
- Notice that the parent page is not immediately visible in the Navigation Bar and appears only after there are child pages like the Benefits Page
At this point, two pages have been created to allow easier access to important PDFs by using a Page title as a link. You can create more child pages in the same way for other important documents. When you click the Benefits page, it opens the PDF in a new browser tab. There is a friendly URL available which can be found by clicking Configure Page to display the page's settings. In this case, it is http://www.alpha.com:8080/web/guest/benefits
. Both ways are valid.
Additional Information
One other option to display the contents of the PDF directly on DXP is to use an iFrame portlet. Configure the iFrame portlet using the PDFs URL. Once configured, the PDFs contents appears directly in DXP.