Skip to main content
frankz60228614
Participant
Jul 27, 2017 1:54 PM UTC
Question

Dynamic Form Submit URL

As you can see, there is a submit button trigger action to submit form. how can I change the url when this button is clicked, for example append datetime to the url so the form data will be send to button.ca/reports?datetime=20170727091214 instead of button.ca/reports

This topic is closed to new replies. Start a new post to keep the conversation going.

6 replies

Participant
Aug 23, 2018 5:43 PM UTC

Does this tool support submit to facebook?

Thank you

Translate
Joel Geraci
Community Expert
Community Expert
Aug 23, 2018 6:04 PM UTC

Vietten:

Can you elaborate?

Translate
try67
Community Expert
Community Expert
Jul 27, 2017 2:22 PM UTC

Instead of the Submit Form action add a Run JavaScript command to your button's Mouse Up event, with this code:

var targetURL = "http://button.ca/reports?datetime=" + util.printd("yyyymmddHHMMss", new Date());

this.submitForm({cURL: targetURL, cSubmitAs: "PDF"});

Translate
Karl Heinz  Kremer
Community Expert
Community Expert
Jul 27, 2017 2:15 PM UTC

You can create a Javascript action that submits your form. Take a look here for information about the Doc.submitForm() method:

Acrobat DC SDK Documentation

By using the JavaScript approach, you can dynamically adjust your submission URL. 

Translate