Jump to content

How to code the transfer of an image from a Squarespace website to a Google document

Recommended Posts

I would like to do the following and would be grateful for any advice how to approach the coding (assuming that it is possible):

I created my website (currently private) that is being hosted on Squarespace;

On one page on my website, there is an image of an animal. The user can click the image of the animal to change it to a new photo (out of ~ 1000 images that I’ve loaded onto my site). Let’s say if a user clicks on the animal, it may change from a photo of a cat to dog, or a photo of a dog to monkey, etc.

When the user likes one of the images, let’s say the image of a dog, I want my site to have the option of clicking a button “write a story using Google docs”. Upon clicking this button, I want to program to: a) take a screenshot of the photo of the animal; b) open Google docs in a new tab; c) allow the user to log into their Google docs; and, d) my program places a copy of the photo/screenshot at the top of a new Google doc.

Using my example described above, the new Google doc will have an image of the dog in the document header space. The user can then write their story in the otherwise blank Google doc. At that point, this Google document with the image of the dog in the header will no longer be associated with my website; that is, at this point, the Google document will be saved in the user’s own personal Google drive.

In summary, I want to know how to code to take a screenshot of the image and transfer the image to a Google document header or into the upper section (ie the upper 25%) of the doc.

One major issue is that any solution must be compatible with the use of Squarespace.

To clarify, every user will have their own personal Gmail account; I do not want to have access to their document.

Many thanks. I do not have any code written yet and would be grateful for any recommendations how to get started, and most importantly, if this is possible.

Link to comment
  • Replies 0
  • Views 245
  • Created
  • Last Reply

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.