Results 1 to 6 of 6

Thread: html link to PDF anchor

  1. #1

    Thread Starter
    New Member
    Join Date
    Mar 2005
    Posts
    2

    html link to PDF anchor

    Can I use something similar to

    <a href="test.htm#part3">go to part 3</a>

    for a pdf document?
    So to create a link to opens PDF document at a certain page?

    Thanks

  2. #2
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170

    Re: html link to PDF anchor

    Edited: I was wrong!
    Last edited by mendhak; Apr 11th, 2007 at 10:26 AM.

  3. #3
    Member
    Join Date
    Oct 2005
    Posts
    35

    Re: html link to PDF anchor

    Here is a function that I wrote (not really much of a function, because you could easily just do it in html, but then it requires more copying and pasting) which helps me load a specific page of a PDF file.

    Code:
    <!-- <script type="text/javascript">
    
    function pagechange(page)
    {
    var beforepage="../../desiredfile.pdf#page="
    self.location.href=beforepage + page;
    }
    
    </script> -->
    Then just create links for it:
    Code:
    <a href="#" onClick="pagechange(1)">1</a> //page 1 of PDF file
    <a href="#" onClick="pagechange(2)">2</a> //page 2 of PDF file
    <a href="#" onClick="pagechange(3)">3</a> //page 3 of PDF file
    <a href="#" onClick="pagechange(4)">4</a> //page 4 of PDF file
    <a href="#" onClick="pagechange(5)">5</a> //page 5 of PDF file
    and of course you should probably make it load in a seperate window/frame, so make sure to use the target if you don't want to change the active window.
    Last edited by konithomimo; Oct 12th, 2005 at 07:52 AM.

  4. #4
    New Member
    Join Date
    Apr 2007
    Posts
    1

    Re: html link to PDF anchor

    R u trying to create anchor within the pdf document and link it from html?

    U can define a destination and then create bookmark for it. You should then be able to link from html to the certain point of the pdf document.

  5. #5
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170

    Re: html link to PDF anchor

    http://www.sitename.com/abc/filename.pdf#page7

    I believe I saw something like this which can be used. However, this thread is 2 years old.

  6. #6
    New Member
    Join Date
    May 2010
    Posts
    1

    Re: html link to PDF anchor

    To make this work, in Adobe Acrobat Professional (I use Adobe Acrobat 9 Pro) create a 'Destination link' --this is like bookmarking a page. In Adobe Acrobat Pro, go to 'View > Navigation Panels > Destinations.' In the Destinations panel, go to the upper left and click the wheel-like icon and select the 'New Destination' option. Name your Destination -- again, this is like your bookmark that you will anchor to.

    After setting your destination, save your changes in the PDF. Upload the PDF. You can now anchor to your saved destination/bookmark by adding '#' at the end of your link and your destination name.

    Example: http://www.sitename.com/abc/filename...estinationname

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width