In the Report (e.g. Crystal Reports) or a document (MS Word) to be exploded by PDF-eXPLODE, any text (for example "Click Here") that is configured as an HTML Hyperlink (highlight text, right click and select 'Hyperlink') will not convert to a web link when this document is converted to PDF.
To understand what works in most generic PDF creators like PDF-eXPLODE, we need to review the various types of hyperlinks available as well as the difference in how a PDF is produced by a PDF Printer engine as opposed to the PDF created via an Export in Crystal Reports or a Save A s in MS Word or Excel.
PDF PRINTER ENGINES:
Every PDF creation engine in the marketplace (and that includes Adobe PDF engine) create PDFs from the Windows created Print output - the source of this output is a windows postscript driver. The postscript driver translate your report page to a formatted Postscript language page which the PDF engine will then convert to a PDF. The output is sourced from Windows, created by the Window's driver using standard postscript language. The driver is not capable of "seeing" the hidden HTML hyperlink tags and hence the HTML hyperlink is not preserved.
SOME REPORT WRITER ENGINES:
On the other hand, Crystal Reports Export or MS Word/Excel Save As PDFs are not generated using the assistance of the Windows postscript driver - so they are not restricted to the limitations of the standard language. Word, Excel and Crystal Reports all use a Macro script which converts the report into PDF using an extended postscript language which is capable of converting HTML hyperlinks to "hyperlink postscript", thereby preserving the link click. HTML hyperlink are not part of standard postscript language driver. If you opted to "Print" to any PDF engine rather than Export to PDF in Crystal Reports would find that the hyperlink is not "clickable".
Here are some of the different forms of hyperlinks and how they are handled by the PDF /postscript engines (via the Windows postscript driver)
1. HTML Hyperlink
An HTML hyperlink is one where a visible underlined text in your report or document hides a web URL in the background. Clicking the underlined text, generally will access/open a specific web URL address in your default browser. In any HTML document or web page, an HTML hyperlink, although invisible (or masked by the underlined text in front of it), will access the URL site when you click on the underlined text. These type of hyperlinks cannot directly be translated to a hyperlink in a PDF document that is created via a PDF engine using a Windows postscript driver and standard postscript language. An HTML Link example :
<a href=”https://www.pdf-explode.com ”> Click here </a>
Here the text " Click Here " is underlined and visible when displayed in an HTML document or Crystal Report and the URL "https://www.pdf-explode.com" is hidden under the "Click here" text. If you Export to PDF in Crystal Reports or Save As PDF in MS Word or MS Excel, you will be able to jump to the web link " www.pdf-explode.com ". PDF creation engines are incapable of converting the HTML link to a PDF preserved hyperlink. However there is a way around this problem. This is what you can do.
Create the actual web URL (example: www.pdf-explode.com )inside a text object. Place this text object over the top of the underlined Text (example CutePDFFile) y ou wish to make a hyperlink with. Next, make the font of the URL text Arial and color White. Now print the document to any PDF printer (example PDFeXPLODE or Adobe ). On completion of PDF printing, open the PDF and test the link by moving your mouse over the plain underlined text and click it to verify that it goes to the web URL. This is how the text shows in the PDF when you use the menu EDIT/Select All Text
You can see the hidden text string that is selected with the word CUTEPDFFile. When you click the word CUTEPDFFile, you will be able to access the website www.pdf-explode.com because your PDF reader will be able to "see" the white text of www.pdf-explode.com even if your eye can't.
2. A complete URL (https://www.pdf-explode.com )
Most PDF creation engines including PDF-eXPLODE are capable of retaining this link but it may be necessary to make the font Arial in some cases.
3. Short form URL: pdf-explode.com instead of https://www.pdf-explode.com
PDF creation engines are incapable of recognizing an incomplete URL unlike current version web browsers which are capable of displaying the web link despite the fact it is a short form URL.
If PDF-eXPLODE was able to insert an extended postscript “pdfmark “into the Windows created postscript output before creating the PDF, then like Crystal Reports, it would retain the hyperlink too. Unfortunately PDF-eXPLODE, like most other PDF creators, is unable to do so. If you want to include working web/email links in your exploded PDF documents, then do not create output like this:
<a href=” https://www.3000ad.com.au "> Click Here </a> or Click Here or PDF-eXPLODE.com
Just show it as Click here : https://www.3000ad.com.au with Arial font and PDF-eXPLODE will automatically convert that text to hyperlink.
TIP : You can export a complete report to PDF using Crystal Reports. This PDF will contain HTML hyperlinks. Verify it out now. Make sure this exported PDF is saved to a folder and not the desktop. Now open PDF-eXPLODE printer queue window and then drag and drop the Crystal Report (exported) PDF onto the white space of the PDF-eXPLODE window. PDF-eXPLODE will explode and email (as configured) and all of the HTML hyperlinks will be retained in the PDF.
Article ID: 45
Created On: Fri, Dec 5, 2014 at 1:07 PM
Last Updated On: Sat, Apr 25, 2020 at 4:08 PM
Online URL: https://kb.pdf-explode.com/article/html-based-hyperlinks-do-not-get-preserved-when-my-document-is-exploded-to-pdf-45.html