2

In Adobe Acrobat, you can process a document using the "Create Links from URLs" function to automatically detect email and web links in a pdf file and make them live links.

I want to do the same thing for phone numbers.
You can manually tag phone numbers using the tel: code. (tel:+000000000). and they will be active links when viewed from a smartphone. (click the link to initiate a phone call)

I am looking for a script or third party plug-in that can automatically detect phone numbers and tag them. Has anyone run across anything that might do this?

This is probably not a design question, but someone here must have run into this before.

2
  • wouldn't the link format depend on the phone being used? what I mean is, the protocol for triggering a call on an iphone is probably not the same as on Android
    – spiral
    Oct 24, 2014 at 8:45
  • maybe. I have not tested on Android. - But that's not the question. How would one tag many phone numbers in a pdf file, without having to do them all manually?
    – Rsiel
    Oct 24, 2014 at 16:49

2 Answers 2

2
+25

Okay, you can probably script it to automate this even more but this should get you started in a fairly efficient way of doing it.

First, find your phone numbers and replace them with one of the Android+iOS accepted formats. According to Tutsplus:

555-5555 (iPhone Only)
(555) 555-5555 (Android + iPhone)
+1 (555) 555-5555 (iPhone Only)
555 5555 (iPhone Only)
555 555 5555 (Android + iPhone)
+1 555 555 5555 (iPhone Only)
555.5555 (iPhone Only)
555.555.5555 (Android + iPhone)
+1 555.555.5555 (iPhone Only)

So let's use the decimal point style, 555.555.5555. Do a find and replace using GREP.

Find what: \(?(\d\d\d)\)?[-. ‑]?(\d\d\d)[-. ‑]?(\d\d\d\d)
Change to: tel:$1.$2.$3

Now your phone numbers should be tel:123.456.7890

Now do another find searching for tel:^9^9^9.^9^9^9.^9^9^9^9. Click find, then click New Hyperlink from URL. Then find next and repeat.

Once done doing New Hyperlink from URL do another find and replace to remove the tel: from the phone numbers. If you want you can even change the format again.

That find next and repeat is something you could probably script but that's up to you.

7
  • I think I would have to script this, correct? - I see no other way to use GREP within Acrobat except through a Javascript. - Thanks
    – Rsiel
    Nov 14, 2014 at 16:33
  • @Rsiel ooh my mistake I answered entirely for InDesign. Not sure how to do in Acrobat and won't be able to check now until Monday. If I remember I'll look then though and see if I can figure anything out. Use to work for phone book company.
    – Ryan
    Nov 14, 2014 at 20:49
  • Wait… there’s no way at all to make Android understand international phone numbers? That beggars belief. Nov 11, 2015 at 20:15
  • @JanusBahsJacquet ... I said nothing at all about international phone numbers so have no idea what you're talking about
    – Ryan
    Nov 11, 2015 at 20:18
  • The only three formats that include international dialling codes are listed as “iPhone only”; I assumed that if Android is unable to parse +1 555 555 5555 for a US/Canadian number, it would also be unable to parse, say, +33 33 33 33 33 for a French number. It seems quite bizarre that this should be so, though. Nov 11, 2015 at 20:21
-5

This one should work... tel:XXX-XXX-XXXX

1
  • 1
    Should? Why? Have you proofed it? You saw the accepted answer?
    – Mensch
    Nov 11, 2015 at 23:36

Not the answer you're looking for? Browse other questions tagged or ask your own question.