Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to link to a bookmark within a PDF using URL parameters?

When providing a link to a PDF file on a website, is it possible to include information in the URL (request parameters) which will make the PDF browser plugin (if used) jump to a particular bookmark instead of just opening at the beginning?

Something like: http://www.somehost.com/user-guide.pdf?bookmark=chapter3 ?

If not a bookmark, would it be possible to go to a particular page?

I'm assuming that if there is an answer it may be specific to Adobe's PDF reader plugin or something, and may have version limitations, but I'm mostly interested in whether the technique exists at all.

like image 430
Chris Carruthers Avatar asked Sep 24 '08 06:09

Chris Carruthers


People also ask

Can you hyperlink to a section of a PDF?

Choose Tools › Edit PDF › Link › Add or Edit. The pointer becomes a crosshair, and any existing links in the document, including invisible links, are temporarily visible. 2. Drag a rectangle where you want to create a link.


2 Answers

Yes, you can link to specific pages by number or named locations and that will always work if the user's browser uses Adobe Reader as plugin for viewing PDF files.

For a specific page by number:

<a href="http://www.domain.com/file.pdf#page=3">Link text</a> 

For a named location (destination):

<a href="http://www.domain.com/file.pdf#nameddest=TOC">Link text</a> 


To create destinations within a PDF with Acrobat:

  1. Manually navigate through the PDF for the desired location
  2. Go to View > Navigation Tabs > Destinations
  3. Under Options, choose Scan Document
  4. Once this is completed, select New Destination from the Options menu and enter an appropriate name
like image 92
Wayne Avatar answered Sep 22 '22 08:09

Wayne


RFC 3778 section 3 specifies "Fragment Identifiers" that can be used with PDF files, which include nameddest and page.

like image 29
sanxiyn Avatar answered Sep 20 '22 08:09

sanxiyn