Working with PDFs
In this article
Kiosk Pro can display PDF files. The app supports links and specific types of widgets embedded in PDFs.
Other more advanced features, including form fill-in within a PDF, audio or video playback within a PDF, and search within a PDF, are not currently supported.
We highly recommend finding a sample file to view in Kiosk Pro before purchasing the app or spending time in development to ensure that this format can meet your project's requirements.
Kiosk Pro Lite uses the native PDF viewer built into the WKWebView browser engine to display PDFs. To customize the viewing experience, all paid versions of Kiosk Pro use a different library to display PDFs, which can result in display differences.
Navigating within a PDF
By default, Kiosk Pro allows visitors to swipe through a PDF document page by page.
In paid versions of the app, it is also possible to limit navigation to hyperlinks only to create a PDF presentation that feels more like a native web experience or to opt for a page turn animation that feels more like a physical book or magazine. See Page Transition Style for more information.
In Kiosk Pro and Kiosk Pro Enterprise, it is possible to show the navigation bar while viewing PDF and other documents while hiding it for other types of content like HTML web pages.
If the navigation bar is shown, a PDF Multipage icon is displayed when viewing PDFs to allow the visitor to shift to a multipage view that displays thumbnails of each page and more easily navigate through the document. This icon can be disabled in Kiosk Pro Plus or Kiosk Pro Enterprise using the Show PDF Multipage Icon setting.
Customizing the PDF View
Paid versions of the app include the following settings to customize how PDFs are displayed:
- Show Thumbnails When displaying a PDF, you can choose to display a navigation bar with thumbnails of the available pages
- Show Page Numbers When a PDF is displayed, you can choose whether to show a page number.
- Background Color (RGB) or Image Set a custom color or background image when a PDF is not specifically sized to fill the iPad's screen.
- Scroll Orientation Determines whether PDFs displayed using the 'Scroll' Page Transition Style are scrolled horizontally or vertically.
- Size to Fit Determines how PDFs are sized to fit on the screen.
URL Parameters with PDFs
Kiosk Pro supports specific URL parameters to allow you to customize how a specific PDF is displayed. The following are supported:
- page=[page-number] - opens the PDF to a specific page.
For example: https://docs.kioskgroup.com/test.pdf?page=2.
- title=[title] - when using Kiosk Pro with multiple tabs enabled, this parameter defines the title shown for the PDF in the tab. Spaces and special characters must be URL encoded.
For example: https://docs.kioskgroup.com/test.pdf?page=2&title=Test%20PDF allows you to customize the title shown if the PDF is opened in a tab.
- kp_sizeToFit=[sizing behavior] - this parameter would override the Size to Fit setting (configured in the app’s settings) for a specific PDF where:
- 0 = Horizontally
- 1 = Vertically
- 2 = Automatically Show Full Page
- 3 = Zoom to Fill Screen
- kp_useNativeBrowserPDFViewer=[0,1] - this URL parameter would trigger Kiosk Pro to display this specific PDF using the native PDF viewer.
For example: https://docs.kioskgroup.com/test.pdf?kp_useNativeBrowserPDFViewer=1 allows you to use the native PDF viewer for only this test.pdf document.
Multiple parameters can be applied by separating each parameter-value pair with an ampersand character (‘&’).
For example: https://docs.kioskgroup.com/test.pdf?kp_sizeToFit=3.
For example: https://docs.kioskgroup.com/test.pdf?page=2&title=Test%20PDF
Paid versions of Kiosk Pro support printing standard document-size PDFs via AirPrint. Smaller receipt/ticket-style PDFs can be printed through one of the thermal kiosk printer integrations in Kiosk Pro Enterprise.
All versions of Kiosk Pro support the native screen mirroring built into iOS/iPadOS, including the mirroring of PDFs displayed within Kiosk Pro.
PDF takes a long time to load?
If your PDF file is taking longer than expected to load, there are a couple of things you may want to try:
Optimize your PDF for web
Web optimization will make the file smaller and will take significantly less time for loading. To optimize your PDF, open it in Acrobat Pro, click on the Advanced tab and then click on PDF Optimizer. This shows you what is going to be optimized. Click OK and save the file.
Reduce the size of your PDF
The best way to reduce the size of a PDF is before the native file is created into a PDF. In the program you used to create the PDF, here are things to check for the web:
- Images – reduce to 72 dpi and flatten
- Fonts – un-embed as many fonts as possible, especially common ones such as Helvetica, Times, Garamond
- Transparencies – remove or reduce resolution to low.
- Discard user-related information (comments, attachments, etc.)
A specific PDF is not displaying?
Once in a while, there may be a specific PDF that Kiosk Pro’s viewer is not able to display. In this case, the Native PDF viewer can be used for that specific document only by using the alternate parameter kp_useNativeBrowserPDFViewer to trigger the app to display a PDF using the native PDF viewer built into WKWebView/UIWebView. If you do choose to use this parameter, please be aware that Kiosk Pro is now no longer using our PDF library, so any other PDF settings or parameters that you have set up will no longer apply.
For example: https://docs.kioskgroup.com/test.pdf?kp_useNativeBrowserPDFViewer=1 allows you to customize the title shown if the PDF is opened in a tab. https://docs.kioskgroup.com/test.pdf?kp_useNativeBrowserPDFViewer=1 ‘Use Native PDF Library’ article & explain that this parameter is only for individual PDFs but other is for all PDFs?)
PDF doesn't print at correct size?
There is a print sizing issue with dynamically-created PDFs that don't include the filetype suffix .pdf. In this situation, Kiosk Pro is unable to identify the document as a PDF and uses the default sizing used by the underlying browser component. This is a bug which affects all versions of Kiosk Pro. More information on this can be found here.
PDF issues with links?
These 2 parameters are available for looking at and resizing links for troubleshooting purposes:
If you continue to have issues after trying these things, let us know and we can help troubleshoot your issue.
- Added 'page' parameter in version 10.0.3. Added 'title' parameter in version 10.1.
- Added 'kp_sizeToFit' and 'kp_useNativeBrowserPDFViewer' parameters in version 11.0.