Hidden form fields
Sending a post with-d
is the equivalent of what a browser does when an HTMLform is filled in and submitted.
Submitting such forms is a common operation with curl; effectively, to havecurl fill in a web form in an automated fashion.
If you want to submit a form with curl and make it look as if it has been donewith a browser, it is important to provide all the input fields from theform. A common method for webpages is to set a few hidden input fields to theform and have them assigned values directly in the HTML. A successful formsubmission, of course, also includes those fields and in order to do thatautomatically you may be forced to first download the HTML page that holds theform, parse it, and extract the hidden field values so that you can send themoff with curl.