Get and Display Google Spreadsheet Values

1,129 views
Skip to first unread message

Shea Laughlin

unread,
Mar 31, 2016, 11:28:29 AM3/31/16
to Minneapolis St. Paul WordPress User Group
Hello!

This is a total nerd moment, but I'm trying to get data from my vehicle (Automatic adapter --> IFTTT --> Google Spreadsheet) to a WordPress site.  I would like to pull a calculated value from the spreadsheet.  For example, total miles driven.

Does anyone know of a way to get the value of a cell in a Google Spreadsheet and display in a widget?  Here's an example from a theme that I came across.


I'm open to other ideas too.  Maybe there's another way to do it with IFTTT?


Thanks!

Shea


Peter Bockenhauer

unread,
Mar 31, 2016, 10:46:08 PM3/31/16
to Minneapolis St. Paul WordPress User Group
The Google Drive Embedder plugin can display a Google Sheet on a WP page: https://wordpress.org/plugins/google-drive-embedder/

However, don't think you can display a single cell this way.

Maybe use IFTTT to save the data to a text file in Dropbox or another service and somehow pull that into your site.

Interesting project!

Shea Laughlin

unread,
Aug 3, 2016, 12:09:17 PM8/3/16
to Minneapolis St. Paul WordPress User Group
I just picked this project back up again and still haven't found a good answer.  I've found some resources to pull in a full spreadsheet.  What I'm looking to do is to take a cell value from a Google Sheet and use it in a WordPress widget.  That way, the widget will always have an up-to-date value instead of having to manually update it.

Jodi Stammer

unread,
Aug 3, 2016, 12:11:05 PM8/3/16
to mpls-stpau...@googlegroups.com

Have you looked into Zapier?

 

Jodi Stammer
Graphic & Web Designer
Uncorked Design LLC

jodi.s...@comcast.net
763-954-0820

--
You received this message because you are subscribed to the Google Groups "Minneapolis St. Paul WordPress User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mpls-stpaul-word...@googlegroups.com.
To post to this group, send email to mpls-stpau...@googlegroups.com.
Visit this group at https://groups.google.com/group/mpls-stpaul-wordpress.
For more options, visit https://groups.google.com/d/optout.

Nick Ciske

unread,
Aug 3, 2016, 12:27:45 PM8/3/16
to mpls-stpau...@googlegroups.com
Seems like the Sheets API is what you're looking for...

https://developers.google.com/sheets/

_______________________ 
Nick Ciske 
VP Web Engineering, Cimbura.com
@nciske

Shea Laughlin

unread,
Aug 4, 2016, 5:15:18 PM8/4/16
to mpls-stpau...@googlegroups.com
Nick, that's exactly what I was playing around with yesterday!  I got it to work in the API playground... Now I just need to get it working in WordPress.

---
Shea Laughlin | shealaughlin.com | @shealaughlin | LinkedIn

--
You received this message because you are subscribed to the Google Groups "Minneapolis St. Paul WordPress User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mpls-stpaul-wordpress+unsub...@googlegroups.com.
To post to this group, send email to mpls-stpaul-wordpress@googlegroups.com.

Nick Ciske

unread,
Aug 4, 2016, 5:56:29 PM8/4/16
to mpls-stpau...@googlegroups.com
What’s the end goal as far as how you want the data to be specified and accessed (an array, shortcode)?

I roughed out a working plugin with a shortcode that can output single cells (from a public sheet) in about 30 minutes. Needs work and probably some caching, but it’s a solid start (and can be done).

_________________________
Nick Ciske
VP Web Engineering
@nciske

Shea Laughlin

unread,
Aug 5, 2016, 10:29:14 AM8/5/16
to mpls-stpau...@googlegroups.com
That's awesome!  The end goal is to display single cell values from a spreadsheet in widgets automatically.  Go to https://www.livingmilebymile.com/ and scroll down to the trip data section.  This is the info from the spreadsheet that I want to update automatically.

It could be a shortcode or even a line of code that I need to put in the widget - Not too picky.



---
Shea Laughlin | shealaughlin.com | @shealaughlin | LinkedIn

Shea Laughlin

unread,
Aug 29, 2016, 11:08:45 PM8/29/16
to Minneapolis St. Paul WordPress User Group
Hey Nick,

Any new updates on this one?  I started to look at this again and have come across a few roadblocks... Specifically around API authentication and getting a response from Google.  I thought I was going in the right direction, but I'm stuck.

Thanks!

Nick Ciske

unread,
Aug 29, 2016, 11:51:30 PM8/29/16
to mpls-stpau...@googlegroups.com
Nope. I haven't done any more on this -- lots of competing priorities these days.

_______________________ 
Nick Ciske 
CTO / Director of Web Engineering
@nciske

Shea Laughlin

unread,
Aug 30, 2016, 9:10:02 AM8/30/16
to Minneapolis St. Paul WordPress User Group
No worries - Any pointers that you can provide on how you got yours to work?

Thanks!
Shea
Reply all
Reply to author
Forward
0 new messages