This project is not covered by Drupal’s security advisory policy.
What does it do?
Field type
This module provides a new field type called "Google sheets table" which accepts a Google sheet spreadsheet ID and converts it into an HTML table. This HTML is stored in the database and can be rendered like a text field, exported to a decoupled app or used however else you like!
Cron task
Additionally, it provides a cron task that automatically checks if the linked Google sheets have any new revisions and updates the respective HTML tables in the database.
How do I authenticate this module with Google?
Follow Google's instructions to create a user-managed Service account. Create a key for this Service account (choose JSON) and download the JSON file. Then store the JSON file as a multi-value key using the Key module. On your Drupal site, go to /admin/config/services/google-sheets-table
and choose the Key you just created as the Google sheets API key. Now the module can view any Google sheets that the Service account has access to. Note that this module does not require write permissions and will only ever read data from Google sheets.
What is a spreadsheet ID?
The spreadsheet ID is the randomized string of characters in the url of the spreadsheet after /spreadsheets/d/
. For example, this spreadsheet https://docs.google.com/spreadsheets/d/1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs... has an ID of 1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgvE2upms
.
See the official Google Sheets API for more information on their terminology.
What Google sheet data is converted to HTML
This module focuses on formatted cell values. For example, if a cell's data is 1.5 but it is set to format as US currency, then it will be converted to <td>$1.50</td>
. Charts, images and other media are not supported. Bold formatting is converted to the <b>
tag and italics are converted to the <em>
tag. Links are also fully supported as <a>
tags. However, the font, font-size, color, background-color, border and alignment of a cell is ignored. The text format is configurable so that any unwanted tags can be stripped in the rendered table.
Logo image credits:
- Down arrow by Rahmat Hidayat from Noun Project
- Table by LAFS from Noun Project
- Screen of computer by verry poernomo from Noun Project
Project information
- Minimally maintained
Maintainers monitor issues, but fast responses are not guaranteed. - Module categories: Content Editing Experience, Content Display, Site Structure
- Ecosystem: Content Components
- 8 sites report using this module
- Created by jayhuskins on , updated
- This project is not covered by the security advisory policy.
Use at your own risk! It may have publicly disclosed vulnerabilities.