Re: Use target="_blank" in embedded PDF links?

Subject: Re: Use target="_blank" in embedded PDF links?
From: Chris Morton <salt -dot- morton -at- gmail -dot- com>
To: "techwr-l -at- lists -dot- techwr-l -dot- com" <techwr-l -at- lists -dot- techwr-l -dot- com>
Date: Thu, 24 Aug 2017 16:09:45 -0400

So I found an Acrobat plug-in by the name of AutoBookmark.

It has a link tool that swaps each URL for a JavaScript counterpart:
app.launchURL("some.url.com", true);

Unfortunately, Chrome doesn't support this JS function (of course not).

It now looks like this idea is a total bust.

Chris Morton
(click logo â for details)
<http://www.the-efa.org/dir/memberinfo.php?mid=15271>
â Substantive Editing â Technical Writing â Proofreading
â B2B/B2C â Marketing Expertise â Mentoring



On Thu, Aug 24, 2017 at 8:56 AM, Chris Morton <salt -dot- morton -at- gmail -dot- com> wrote:

> Acrobat Pro includes a JavaScript editor, and this code is supposed to
> open every link in a new window:
>
>
> function externalLinks()
> { for(var c = document.getElementsByTagName("a"), a = 0;a
> < c.length;a++) { var b = c[a]; b.getAttribute("href")
> && b.hostname !== location.hostname && (b.target = "_blank") } } ;
> externalLinks();
>
>
> When I use the JavaScipt Editor, it displays this by default:
>
> //-------------------------------------------------------------
> //-----------------Do not edit the XML tags--------------------
> //-------------------------------------------------------------
>
>
> So I'm guessing this is how it goes together:
>
> //-------------------------------------------------------------
> //-----------------Do not edit the XML tags--------------------
> //-------------------------------------------------------------
> <script>
> function externalLinks()
> { for(var c = document.getElementsByTagName("a"), a = 0;a
> < c.length;a++) { var b = c[a]; b.getAttribute("href")
> && b.hostname !== location.hostname && (b.target = "_blank") } } ;
> externalLinks();
> </script>
>
>
> But when I click *[OK]*, the JS Editor complains about the <c.length;a++
> syntax.
>
> Anyone know why?
>
>
>
>
>
> Chris Morton
> (click logo â for details)
> <http://www.the-efa.org/dir/memberinfo.php?mid=15271>
> â Substantive Editing â Technical Writing â Proofreading
> â B2B/B2C â Marketing Expertise â Mentoring
>
>
>
> On Thu, Aug 24, 2017 at 8:16 AM, Chris Morton <salt -dot- morton -at- gmail -dot- com>
> wrote:
>
>> Apparently the AutoBookmark plug-in lets me do this, but it's $189....
>> WAY too expensive for the single page I want to perform this single
>> operation on.
>>
>> Another person has a different tool, but it requires every viewer to have
>> Java installed; that's too much of a restriction.
>>
>> Chris Morton
>> (click logo â for details)
>> <http://www.the-efa.org/dir/memberinfo.php?mid=15271>
>> â Substantive Editing â Technical Writing â Proofreading
>> â B2B/B2C â Marketing Expertise â Mentoring
>>
>>
>>
>> On Thu, Aug 24, 2017 at 7:59 AM, Chris Morton <salt -dot- morton -at- gmail -dot- com>
>> wrote:
>>
>>> I'm using Acrobat Pro DC.
>>>
>>> I'm required to use its Edit mode, then create a sort of bounding box
>>> around the item I want to link. From there, Acrobat offers few options.
>>>
>>> I have no trouble inserting the URLs to create each link, but simply
>>> tacking on a *target="_blank"* does not yield the desired result when I
>>> open the resulting PDF in a browser.
>>>
>>> Chris Morton
>>> (click logo â for details)
>>> <http://www.the-efa.org/dir/memberinfo.php?mid=15271>
>>> â Substantive Editing â Technical Writing â Proofreading
>>> â B2B/B2C â Marketing Expertise â Mentoring
>>>
>>>
>>>
>>> On Wed, Aug 23, 2017 at 3:48 PM, Chris Morton <salt -dot- morton -at- gmail -dot- com>
>>> wrote:
>>>
>>>> If so, how can I do this?
>>>>
>>>> Thanks
>>>>
>>>> Chris Morton (click logo â)
>>>>
>>>> <http://t.sidekickopen68.com/e1t/c/5/f18dQhb0S7lC8dDMPbW2n0x6l2B9nMJN7t5XYgdnqQxW7fsH3H4XrddKW1pNgV-56dMhqf2Q-c6C02?t=http%3A%2F%2Fwww.the-efa.org%2Fdir%2Fmemberinfo.php%3Fmid%3D15271&si=6020636811198464&pi=74057096-fb97-48e7-c59d-70bfe6671665>
>>>> â Substantive Editing â Technical Writing â Proofreading
>>>> â B2B/B2C â Marketing Expertise â Mentoring
>>>>
>>>>
>>>>
>>>
>>
>
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Visit TechWhirl for the latest on content technology, content strategy and content development | http://techwhirl.com

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

You are currently subscribed to TECHWR-L as archive -at- web -dot- techwr-l -dot- com -dot-

To unsubscribe send a blank email to
techwr-l-leave -at- lists -dot- techwr-l -dot- com


Send administrative questions to admin -at- techwr-l -dot- com -dot- Visit
http://www.techwhirl.com/email-discussion-groups/ for more resources and info.

Looking for articles on Technical Communications? Head over to our online magazine at http://techwhirl.com

Looking for the archived Techwr-l email discussions? Search our public email archives @ http://techwr-l.com/archives


References:
Use target="_blank" in embedded PDF links?: From: Chris Morton
Re: Use target="_blank" in embedded PDF links?: From: Chris Morton
Re: Use target="_blank" in embedded PDF links?: From: Chris Morton
Re: Use target="_blank" in embedded PDF links?: From: Chris Morton

Previous by Author: Re: Use target="_blank" in embedded PDF links?
Next by Author: Re: Use target="_blank" in embedded PDF links?
Previous by Thread: Re: Use target="_blank" in embedded PDF links?
Next by Thread: Re: Use target="_blank" in embedded PDF links?


What this post helpful? Share it with friends and colleagues:

Sponsored Ads


Sponsored Ads