Rocket NXT
To integrate PDF Highlighter with Rocket Folio NXT, update xhitlist.xsl
template file.
Step 1: Include and init Highlighter JS
Update <xsl:template match="/">
section by adding the following to the end of document <head>
section:
This code snippet loads jQuery PDF Highlighter plugin and initializes it, attaching Highlighter to all links having data-uri
attribute (which we add in Step 3).
We assumed here that Highlighter is available under the /highlighter
path on the same IIS website (e.g. setup using reverse proxying).
Step 2: Add query attribute to the results table
Find search results table header, and add the data-query
attribute. The relevant section looks like the sample below — the added line is #2.
Step 3: Modify result links to PDF documents
Find the template <xsl:template name="build-document-link">
, and update the section that controls the PDF document link construction — so it looks like this:
Note that we added both uri
and viewUrl
attributes:
uri
parameter will be used by Highlighter to locate the PDF document. Setup serving local files to properly map uri to a local file.viewUrl
parameter will be used in the document serving path so, when highlighting PDF viewer is used, the user receives the PDF document through Rocket NXT.
note
The above code snippet assumes that the $path node contains a valid path to the PDF document on file system. If your indexer transforms the path — so it doesn't reflect the file system path any more — you should store the original file path in another node (e.g. $title-path) and reference this node in line #3.