Download a zip from a servlet Java
问题 I don't understand why this is so hard and everybody has it's own implementation... So in my server, I generate a .zip file which I want the user to be able to download upon click. So I set up the request, which the server successfully receives and now, i'm struggling with writing the byte array to the output. Here's my code for the response: protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { // TODO Auto-generated method stub