Search code examples
javascriptpdfweb-scrapingadobeacrobat

PDF forms get online content


Would it be possible to use the inbuilt Javascript in adobe pdf forms to get contents/scrape a web page?

When I googled if Javascript could do this there where CSP errors, but pdf forms does not have this as far as I know.

thanks, g3


Solution

  • As you suspected, it is not possible to achieve this with Acrobat's Javascript extensions.

    There are a number of third party tools that can convert a website to a pdf. If you also need to build a form, rather than just convert a webpage, you could write a program that would leverage a third party conversion tool, then build the form using Acrobat's Interapplication Communication API reference. If you're more comfortable with Javascript, you could even use the PDDoc's JSObject to build the form with Javascript.