Is it possible to download a file with HTTP POST? I know the \"Get\" way(windows.location), but in my case, there are a lot of param that should be passed to server
In some sense, every HTTP GET or POST is "downloading a file", but it's better to think of it as the message payload rather than a file. In most cases, the payload is an HTML document that the browser should render as a web page. But what if it's not an HTML document? What if it's a zip file for which the browser should offer the user a "Save as" dialog? Obviously, the browser must make a determination about the content type of the response and handle it correctly.
One of the most common ways that a browser determines the content type is through a HTTP header called, accordingly, "Content-Type". This header takes the value of a mime-type. This is the key to browsers doing content specific things like firing up an acrobat plugin when the response contains a pdf file, etc.
Note, not all browsers 1) determine the content type in the same way, and 2) react to the content type in the same way. Sometimes you have to toy with setting the headers to get the behaviors you want from all the browsers. All server side technologies allow you to set HTTP headers.