title: How to prevent auto download of doc/docx/pdf file on iframe src
body: <p>I want to build a blurred preview of the document. The document is uploaded to the same domain. The document can be <strong>doc/docx/pdf</strong>. I tried so many workarounds with <code>iframe</code>, <code>embed</code>, <code>object</code>.</p>
  
  <p><code>&lt;iframe src="URL" title="Embedded Document" style="width:100%; height:500px; border: none;"&gt;&lt;/iframe&gt;</code></p>
  
  <p><code>&lt;iframe src="URL#toolbar=0" title="Embedded Document" style="width:100%; height:500px; border: none;"&gt;&lt;/iframe&gt;</code></p>
  
  <p><code>&lt;embed src="URL"&gt;</code></p>
  
  <p><code>&lt;object data="URL"&gt;&lt;/object&gt;</code></p>
  
  <p>But nothing achieve my requirement.</p>
  
  <p><strong>TASK:</strong>
  I want to show a preview of the document on the web page which can not be downloadable. Above workarounds, auto-downloads the doc/docx file when I refresh the web page. I want a blurred preview of the document like here: <a href="https://essaybatch.com/how-would-you-convene-and-run-your-meetings-if-you-are-based-in-the-united-states/" rel="nofollow noreferrer">https://essaybatch.com/how-would-you-convene-and-run-your-meetings-if-you-are-based-in-the-united-states/</a>  and the file shouldn't be auto-downloaded.</p>
  
  <p>This requirement is strongly stated by the client, so I can't avoid the feature. You're able to use HTML,CSS,JS,PHP. </p>