Embed a link and preview of Google Drive Documents by pasting a shared document link into the editor.
This plugin supports auto-embedding various types of Google Drive content. Just paste a public or shareable URL directly into your editor.
Note: The trailing part of the URL (like
/edit
,/view
, or/viewform
) is optional. These are commonly included when users copy URLs directly from the browser, and the embed handler accepts them.
-
Google Docs
Example:https://docs.google.com/document/d/FILE_ID/edit
-
Google Forms
Example:https://docs.google.com/forms/d/FILE_ID/viewform
-
Google Sheets
Example:https://docs.google.com/spreadsheets/d/FILE_ID/edit
-
Google Slides
Example:https://docs.google.com/presentation/d/FILE_ID/edit
-
Google Drawings
Example:https://docs.google.com/drawings/d/FILE_ID/edit
-
Google Drive files (generic)
Example:https://drive.google.com/file/d/FILE_ID/view
-
Google Drive shared links by ID
Example:https://drive.google.com/open?id=FILE_ID
Requires at least: 5.5
Tested up to: 6.8
License: GPLv2 or later
Requires PHP: 7.4+
- Download the plugin from here
- Add the plugin from the WordPress admin panel.
- Activate the plugin through the 'Plugins' menu in WordPress
- Copy the URL of drive document which you want to embed. Note: The document must be shared with anyone with the link.
- Create new post/page or edit existing one.
- Paste the URL in the editor. It will automatically embed the document.
Screen.Recording.2023-12-15.at.1.15.39.PM.mov
- Please verify your code is in compliance to the Coding Standards used in this Project.
- Run
composer phpcs filename
orcomposer phpcs
to check for PHPCS errors/warnings.
- Run
npm install
from repositories root to install all required dependencies. - To build a production version run
npm run build
. - While developing the plugin run
npm run dev
to build assets on file changes. - If any string is added/updated, run
npm run language
to update the language file. ( Assumes availability ofwp i18n
command. )