Fill out a form automatically using curl and php
问题 I am trying to write a script that fills out forms automatically and then automatically presses the submit button. I have read that you can use curl to post HTTP requests, but what do you do when the form handles the post request with JavaScript, like the code below? <form name="myform" action="javascript:void(0)" method="POST" onsubmit="return fancy_function(this)"> 回答1: Based off your answer to the comments above, what you want to do is not "fill out the form" with curl, but rather post the