I need to make a post call to a url with parameters lets say a="x", b="y", c="z" and d which is form data field. It is the file that i upload in the html form. On making an ajax call, i call.
$.ajax({
contentType: false,
processData: false
type: 'post',
url:"some url i put here",
data: {
a: "x",
b: "y",
c: "z",
}
})
.done(function(data){
alert("Data: ", data);
});
HTML part is
<body>
<input id="filey" type="file" size="40"><br><br>
<button>Send an HTTP POST request to a page and get the result back</button>
</body>
</html>
Note that a,b,c are known to me beforehand. How do i pass d?