title: File download in REST uing jersey and RESTclient in firefox not showing download pop up
body: <p>I'm writing a code to download files using ReST API. my code is working fine and I am getting a response back.
  But  i am getting the file content as  response body in browser rather than asking for a file download</p>
  
  <p>below is the sample code I am using.. please help me to figure out what i am doing wrong.
  I tried all the codes posted in SO that matched with my requirement but still i could not get the pop up .</p>
  
  <pre class="lang-java prettyprint-override"><code>@Path("/downloadfiles")
  public class DownloadFiles {
  
      @GET
  
      @Produces("text/plain")
      public Response getFiles( ) {
  
          File file = new File("/opt/test/sample.csv");
          ResponseBuilder response = Response.ok((Object) file).header("Content-Disposition",
                   "attachment; filename=sample.csv");
  
          return response.build();
  
      }
  }
  </code></pre>
  
  <p>Thanks.</p>