Updates: Release JLex Review v6.1.7 🥳

How to embed PDF, Word, Excel or Powerpoint files to website

As you know, Google Docs now supports inserting document files into website via IFRAME tag.
Not stopping there, Google Docs also supports inserting documents from remote URL. That means you can use the Google docs reader to display documents on your own website.

Google Docs supports reading of many different file types. Popular are: PDF, Word, Excel, and PowerPoint.

Example the URL to word file on your website is: https://www.example.com/mydoc.docx

Now follow these steps to insert this word file into your website:

  1. Visit site to encode URL to file.
    The URL after encoded is: https%3A%2F%2Fwww.example.com%2Fmydoc.docx
  2. The direct URL to read your file is: https://docs.google.com/viewer?url=https%3A%2F%2Fwww.example.com%2Fmydoc.docx&embedded=true
  3. Use the IFRAME tag to embed this URL on your website.
    <iframe src="https://docs.google.com/viewer?url=https%3A%2F%2Fwww.example.com%2Fmydoc.docx&embedded=true" width="700" height="500" frameBorder="0"></iframe>

Note: For safety reasons, the IFRAME tag may not be saved by default. To save this tag, GOTO System > Global Configuration > Site > Default Editor: Editor - None.

Say something here...
Cancel
You are a guest ( Sign Up ? )
or post as a guest
Loading comment... The comment will be refreshed after 00:00.
Sign in to your account

Use your social accounts to sign in