title: how to display pdf file in pop u window in jsp
body: <p>i a m already done my pdf view but now i want just view dynamically pdf file pop window not download option and save option so please give some example in java
  i a m use this code now </p>
  
  <pre><code>File f= new File(file);
  if(f.exists()){
  ServletOutputStream op= response.getOutputStream();
  response.reset();
  if(check==1){
  response.setContentType("application/pdf");
  }else{
  response.setContentType(content);
                      }
  // response.setHeader("Content-disposition","attachment;      filename=" +fileName);
  byte[] buf = new byte[4096];
  int length;
  DataInputStream in = new DataInputStream(new FileInputStream(f));
  while ((in != null) &amp;&amp; ((length = in.read(buf)) != -1)){
  op.write(buf,0,length);
              }
  in.close();
  op.flush();
  op.close();
      }  
  </code></pre>