Google

Google Event Ilustrations aka Flairs

Source: http://www.internetbestsecrets.com/2019/09/google-calendar-event-images.html
art: painting, art workshop, sketching workshop, drawing workshop
badminton: badminton
baseball: baseball
basketball: basketball
bbq: bbq, barbecue, barbeque
beer: beer, beers, Oktoberfest, October Fest, Octoberfest
billiard: billiard
bookclub: book club, reading
bowling: bowling
breakfast: breakfast, breakfasts, brunch, brunches
camping: camping
chinesenewyear: chinese new year, chinese new years, chinese new year's
cinema: cinema, movies
clean: cleaning, clean the house, clean the apartment, clean house, tidy up, vacuum clean, vacuum cleaning
code: learn to code, coding time, hackathon, Rails Girls, Railsgirls, Hour of Code, Codecademy, Computer Science, Programming in Python, Web Programming, Programming in Java, Web Development
coffee: coffee, coffees
concert: concert, gig, concerts, gigs
cycling: bicycle, cycling, bike, bicycles, bikes, Biking
dancing: dance, dancing, dances
dentist: dentist, dentistry, dental
dinner: dinner, dinners, restaurant, restaurants, Family meal
drinks: cocktail, drinks, cocktails
golf: golf
graduation: graduation
gym: gym, workout, workouts
haircut: haircut, hair
halloween: halloween, helloween, hallowe'en, Allhalloween, All Hallows' Eve, All Saints' Eve
hiking: hiking, hike, hikes
kayaking: kayaking
learninstrument: piano, singing, music Class, choir practice, flute, orchestra, oboe, clarinet, saxophone, cornett, trumpet, contrabass, cello, trombone, tuba, music ensemble, string quartett, guitar lesson, classical music, choir
learnlanguage: French Course, German Course, English Course, …, French Class, German Class, English Class, …, Practice French, Practice German, Practice English, …
lunch: lunch, lunches, luncheon
manicure: manicure, pedicure, manicures, pedicures
massage: massage, back rub, backrub, massages
newyear: new year, new year's, new years
oilchange: oil change, car service
pingpong: ping pong, table tennis, ping-pong, pingpong
planmyday: plan week, plan quarter, plan day, plan vacation, week planning, vacation planning
pride: dyke march, christopher street day, gay parade, gay pride, gayglers, gaygler, lesbian march, lesbian parade, lesbian pride, euro pride, europride, world pride, worldpride
reachout: reach out to, write letter, send invitations
read: reading, newspaper
repair: fridge repair, handyman, electrician, DIY
running: jog, jogging, running, jogs, runs
sailing: sail, sailing, boat cruise, sailboat
santa: Santa Claus, Father Christmas
skiing: skiing, ski, skis, Snowboarding, snowshoeing, snow shoe, snow boarding
soccer: soccer
swimming: swim, swimming, swims
tennis: tennis
thanksgiving: thanksgiving
violin: violin, violins
walk: going for a walk, walking
wedding: wedding, wedding eve, wedding-eve party, weddings
xmas: christmas, xmas, x-mas
xmasmeal: christmas dinner, christmas lunch, christmas brunch, christmas luncheon, xmas lunch, xmas luncheon, x-mas dinner, x-mas lunch, x-mas brunch, x-mas luncheon, christmas eve dinner, christmas eve lunch, christmas eve brunch, christmas eve luncheon, xmas eve dinner, xmas eve lunch, xmas eve brunch, xmas eve luncheon, x-mas eve dinner, x-mas eve lunch, x-mas eve brunch, x-mas eve luncheon
xmasparty: christmas party, xmas party, x-mas party, christmas eve party, xmas eve party, x-mas eve party
yoga: yoga

What?
A super quick article to show how to link to the thumbnail image of a Google Drive file, in this case a video file.

How?
The hardest part of this is to get the Google Drive File ID (which you need for the below). The image link (src) will be as below but then this is a redirect to the actual thumbnail stored by Google Drive:
https://drive.google.com/thumbnail?authuser=0&sz=w320&id=<GOOGLE_DRIVE_FILE_ID>

// where <GOOGLE_DRIVE_FILE_ID> is the file id

What?
This is an article explaining the code needed to write a PHP script which generates an access token for a service account which in turn is used to list files in a team's Google Drive.

This is very different to my code for OAuth when attended: Google Authentication - OAuth 2.0 using PHP/cURL... In that this one doesn't prompt for a user. Again this script doesn't need the client libraries, composer, vendor, etc.

Why?
This took me the best part of a month to get working. It is taken from Google's documentation as well as other forums and websites that try to explain it. Do not waste your time like I did on the public key, verifying a JWT signature, or including any third-party libraries. You can do it in pure PHP and all you need is the JSON key that you generated in your Google console.

Applies to:
  • Google Drive REST API v3
  • Google OAuth 2.0 v4
  • Google Cloud Platform IAM
  • Google Suite
  • PHP v5.6.35

How?
I'm going to go through each section of the code to go through the logic and highlight any changes you may need to make.

What?
This is an article which lists the functions necessary to process Google Authentication using OAuth2.0. These functions allow a script to simply be loaded and to either create a token file, or use the existing one as long as it hasn't expired.

Update 2019
This script requires a user to authenticate the google account. I have a newer article called Google Drive API v3 - OAuth2 using Service Account in PHP/JWT documenting a script which accesses a Google Drive using a Service Account (unattended).

Why?
This is a big cop-out as I simply took someone else's functions and upgraded them to use the mentioned token based authentication. I find myself going through the motion and designing on a per-app basis so I wanted a standard way of doing it and I'll update this article as I improve on the code.

How?

What?
So this is supposed to be a quick article detailing how I used a PHP function to upload a video file to Google Drive. Note that this example does not involve installing the Google Client Library for PHP. So no classes or built-in functions that you didn't write or know what they're doing.

Why?
The objective here is to upload a video file to my Google Drive. This assumes you have already "Enabled the Drive API" via your Google Developers console as well as gotten your OAuth 2.0 access/refresh tokens and specified the appropriate scopes.

The scopes I chose were to do with getting a working example rather than the recommended scope, though you may only need the first (untested):
https://www.googleapis.com/auth/drive.file
https://www.googleapis.com/auth/userinfo.email
https://www.googleapis.com/auth/userinfo.profile

How?
I've listed below 3 methods, the first follows the manual (or the logic thereof as I don't use the client library) and is a function sending two requests, the second is the appropriate multipart function which uploads and names the file in a single request, and the third is a 'nice-to-have' upload to the specified folder.

Subcategories

Please publish modules in offcanvas position.