Is it possible to provide HTTP multipart response just like multipart request? The scenario is like, I would like to provide a URL which takes a parameter for EmployeeID, and in return the response should consist of employee’s photo, latest payslip and information like name, age and address. The receiving end is not a browser, but it will be a program which gets this response and process them later. Any idea on how to do this?
To give more information on my above question, I have to provide a URL to my friend who will programmatically receive the response. For e.g.:
$response = $ua->request($my_url)
My application is supposed to respond with not just data, but also with files! I was being asked to make it to return multipart response.
I’m posing my original https://gist.github.com/1391017 as response.
Output: