Help Contents

Hyperlinks

Print2HTML5 documents can contain hyperlinks in them similarly to web pages. A hyperlink can be clicked by users in order to open the location to which the link points. Hyperlinks in converted Print2HTML5 documents are marked by a special hand mouse cursor when mouse hovers over them in documents. Hyperlinks are clickable only in Drag mode.

Currently there are two methods for hyperlink support. They are detailed below.

Extracting hyperlinks directly from source documents

This method retrieves hyperlinks from source documents that can contain hyperlinks in them and creates corresponding hyperlinks in Print2HTML5 documents. Currently the following document types are supported by this method:

If you do not want your Print2HTML5 documents to contain links from source documents, you may turn this feature on or off using respective checkboxes in the Hyperlinks tab of Document Options window.

Microsoft Word and PowerPoint documents

To convert these types of documents with hyperlinks support, you may use these conversion methods:

  1. By opening Print2HTML5 Application and using Convert button.
  2. By opening Print2HTML5 Application and drag-and-dropping the document on the application window.
  3. By opening them in respectively Microsoft Word or Microsoft PowerPoint and then either choosing "Print2HTML5/Convert to HTML5/SVG format using Print2HTML5" option from the application menu or clicking "Convert to HTML5/SVG format using Print2HTML5" button on the custom Print2HTML5 Toolbar.

At programmatic conversion hyperlink extraction is controlled with ExtractLinks property of Profile object or with ExtractLinks parameter of Enhanced Batch Processing. Also, special application conversion method must be activated in order to enable hyperlink extraction for Microsoft Word and PowerPoint documents.

PDF and AutoCAD documents

To convert PDF and AutoCAD documents with hyperlinks support, you may use these conversion methods:

  1. By opening Print2HTML5 Application and using Convert button.
  2. By opening Print2HTML5 Application and drag-and-dropping the document on the application window.

At programmatic conversion hyperlink extraction is controlled with ExtractLinks property of Profile object or with ExtractLinks parameter of Enhanced Batch Processing. For PDF documents you should use ACROBAT value for this property while for AutoCAD documents - AUTOCAD value.

Bookmarks

Source documents may contain bookmarks in them. Bookmark is a hyperlink that links to another location in the same document. When a bookmark is clicked, the document view is shifted to display the location the bookmark points to. For example, when you click a table of contents heading in a Word document, it takes you to the chapter this heading corresponds to. Print2HTML5 supports bookmarks and retains them in the output Print2HTML5  documents.

You may also navigate to a bookmark using Print2HTML5 Document API. It exposes goToLinkTarget function which allows you to navigate to the bookmark specified by the url parameter. The bookmark should be specified in this format: anchor:<bmname>. Here bmname is the name of the bookmark. For example, if you want to navigate to the bookmark named chapter1, you need to use this parameter value: anchor:chapter1.

Parsing hyperlinks from the document text

For other types of documents you may make Print2HTML5 parse hyperlinks out of document text. If a document contains a text string that looks like a valid URL, Print2HTML5 can convert this string to a hyperlink which is clickable and opens the URL when clicked. The following text patterns are recognized:

  • words starting from "http://", "https://";
  • words starting with "www." (http protocol is implied for such links).

You may control the parsing of such links using "Extract parsable hyperlinks" option in the Hyperlinks tab of Document Options window. At programmatic conversion it is controlled with ParseLinks property of Profile object or with ParseLinks parameter of Enhanced Batch Processing.