dimanche 1 mars 2015

Add links in PDF

I have several PDFs that were generated with Microsoft Word. I want to:



  1. Use a regex to find matches in the PDF text.

  2. Convert the matching text to a link that points to an external URL.

  3. Save the new version of the PDF.


If I were doing this in HTML, it would look like this:



<!-- before: -->
This is the text to match.

<!-- after: -->
This is the text to <a href="http://www.match.com/" target="_blank">match</a>.


How can I do this to a PDF?


I'd prefer Python, but I'm open to alternatives.


Aucun commentaire:

Enregistrer un commentaire