How do I embed a Google spreadsheet into a non-Sites webpage?
April 15, 2013 3:36 PM   Subscribe

I have a spreadsheet with about 3000 rows of data. I would like the contents of this spreadsheet to show up as a big list/table on a webpage. It's mostly text with one column of URLs. The contents will change not-infrequently (maybe every couple of months) and I would like people both inside and outside my organization (but not general visitors to the webpage) to be able to edit the contents.

If it was just about sharing and editing the contents a Google Drive-hosted spreadsheet would be perfect for this purpose. But I need to take it the step further and show the contents on a webpage. It seems that I can do this by embedding the Sheet into a Sites page, but I don't want to use sites. I need to use our own hosted website.

Short of handing this mess to our developer and making some kind of mini-db that gets queried when someone accesses the page + a front end for editing, I figure there must be a way to do this. The page that shows up at the link when I publish the Sheet is almost perfect for my needs, it just needs a header/introduction and a way to not have the Google URL show up as part of the URL.

A script? Something super obvious I'm missing here? How can I get this done?
posted by marylynn to Computers & Internet (3 answers total) 2 users marked this as a favorite
 
Best answer: I've done this before by embedding the published sheet in an iframe. Do something like:

<iframe width='900' height='400' frameborder='0' src='https://docs.google.com/spreadsheet/pub?key=...'></iframe>

The only caveat is that it'll show up with scroll bars if the spreadsheet is larger than the width or height given in the iframe tag. You could tweak them so the iframe is large enough, but that won't guarantee a lack of scroll bars for everyone, due to font size settings, etc.
posted by zsazsa at 3:42 PM on April 15, 2013


Have you tried their html exporter?

Open the spreadsheet, select "File", "Download As", and "Web Page"

This places the spreadsheet data into an HTML table, and you can copy and paste the table information into your own website.
posted by 1367 at 3:53 PM on April 15, 2013


If your site is built on any popular CMS (Wordpress, Joomla etc) there might be a plugin that handles this fairly easily once installed. So this might really be something that's within your developer's purview not yours. Ask them maybe?
posted by springbound at 10:48 AM on April 16, 2013


« Older MS Word / Excel 2011 for Mac catalog merge mystery   |   Cell phone options for a short trip to Canada Newer »
This thread is closed to new comments.