I am trying to automate some stuff and need to then replace some text in a PDF document generated from InDesign. It's on a linux server so I am looking for a PHP script to replace the text - either in the Indesign document or even better the PDF file - if that is even possible?
Asked
Active
Viewed 334 times
1 Answers
0
Why do you rather replace your text in PDF instead of the Indesign file? Isn't is necessary to have your sourcefiles up-to-date?
You probably want to look at IDML which is de XML-based format of Indesign (indd) files. You can probably convert your indd files serverside to idml files.
There are several PHP libraries to read and write within idml files (not tested by me, not a PHP guy). https://github.com/jorisros/IDMLlib https://github.com/deathlyfrantic/php-idml
-
What was something I did consider, but was unable to find anything that could convert the indesign files to PDF. – Michael Nielsen Sep 16 '20 at 18:28
-
If you have Indesign (server) you could also automate this with some Bash and Javascript/Applescript. I don't know of any PHP libraries that converts INDD of IDML to PDF. – MeneerDeBurgemeester Sep 22 '20 at 13:31