Automating creating hyperlinks

New Here ,
Mar 31, 2021 Mar 31, 2021

Copy link to clipboard

Copied

Hi all, I have an issue that takes a lot of time manually to input and I couldn't figure the way to automate it.

Basically client wants to input the twitter handles of multiple users in the pdf and hyperlink the handles so that when you click on the twitter handle it leads to the twitter profile. My only solution was to select the each handle and then input the https: etc... in hyperlink window. Is there a way to do this automatically as it takes a sizeable chunk of my time? Thanks

TOPICS
Scripting

Views

202

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Adobe Community Professional , Apr 01, 2021 Apr 01, 2021
The search pattern you used is for JavaScript (and some other programming languages). Try this one: @\w+ P.

Likes

Translate

Translate
Adobe Community Professional ,
Mar 31, 2021 Mar 31, 2021

Copy link to clipboard

Copied

If these are shown as a url (e.g. https://twitter.com/dianeburns_sf), you can use "Convert URLs to Hyperlinks" on the Hyperlinks panel menu.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Mar 31, 2021 Mar 31, 2021

Copy link to clipboard

Copied

Unfortunately they are not. They are currently shown as @janedoe. I found a script called Gryperlink which can find and add hyperlink but I'm having trouble editing the script so it works. All it does now is find the characted @ and adds the hyperlink and I want it to add hyperlink/username

 

This is the script:

searchPattern: /[@]/g,
link: "https://twitter.com/$1",
charStyleName: "Hyperlink",

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Community Professional ,
Apr 01, 2021 Apr 01, 2021

Copy link to clipboard

Copied

The search pattern you used is for JavaScript (and some other programming languages). Try this one:

@\w+

P.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Apr 05, 2021 Apr 05, 2021

Copy link to clipboard

Copied

LATEST

Hi Peter,

thank you VERY MUCH for the tip, now it does add hyperlink to the whole word with @ and the link actually leads to the designated twitter profile.

You just saved me 4 hours of work every week. Thank you.

Just in case someone else needs to find it, here is the code:

searchPattern: /(@\w+)/g,
link: "https://twitter.com/$1",

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines