Using PHP to retrieve Google Spreadsheet as HTML - php

I'm thinking that someone might of already solved this problem. I tried to look at the Spreadsheets API and there's no mention of being able to download the file. cURL might be an option but I'd rather not get into the hassle of authenticating / POSTing manually.

You can take a look at Dynamic FAQ Section w/ jQuery, YQL & Google Docsif you want something like this.

This should help you out: http://code.google.com/apis/spreadsheets/data/1.0/developers_guide_php.html
Although C# this will help too: How to download Google SpreadSheets using C#?

Related

Calendar export (Webcal)

I would like to give users of my website the opportunity to export their calendar, but I'm not sure how to do this.
I have read about two differents way, .ics file and webcal.
.ics file, this file they have to download (does it work on mobiledevices)?
webcal, i saw on another website that I could subscribe to an url with webcal:// and then get the calendar informations.
I have tried to read on it on this forum and google it, and found out that I could use a tool like http://www.davical.org/, but it seems quite hard, so I don't know if I understands it right?
I had hoped there was a way to just do it yourself in php, and then offer the users the webcal:// address, but maybe it is a way bigger task?
Edit If the users of the calendar only have to have read access when they subscribes to the webcal, can you then just do it like this? - a href="webcal://calendar.ics">webcal ics link/a?
Hopes someone can make it more clear for me:-)
Thanks, Andreas
It seems like that I can just make a .ics file like this in this tutorial - https://gist.github.com/jakebellacera/635416. And then i can call this .ics file like this.
calendar
I dont know if it's the right way to do it, but it seems like it works for me.
yep your webcal link will work, but be aware that webcal is not an officially supported URI, so your mileage will vary. In particular, it doesn't work on Android phones.

How could I download videos from youtube using php?

So, i would like to download youtube videos using a php script. I have googled a lot for now and there where more solutions but the one was using the http://youtube.com/get_video?data url but that is not possible now for a long time. I have found a greasemonkey script which works fine but i don't have a clue how could it work with php.
I have read that i must do something with the info which gives me for example this link:
http://www.youtube.com/get_video_info?video_id=g1SADcP5g1o
The question is what would be the best approach for this?
I would try to get some curl requests going on any of these resources and try to automate it that way.
I have it written in C++, not PHP. But it's not very simple yet not very complicated either. get_video_info output is URL encoded. Decode it and look for the stream_map set of streams. You'll notice a pattern in it. That's your starting point. Contains resolutions and download locations plus extras.
I wouldn't paste the PHP code here even if I had it :) They tend to change it...

how to add google map in a page using php,jquery

Im working on a project..I have to add a google map of my location.Im new to this so any help will be appreciated . I know there are many tutorial but i cant find the best one.Thanks in advance :)
you might want to start here. This a tutorial from Google.
Google Maps API is very powerful but you need to have detailed information about Javascript (Jquery), PHP, mySql etc. Also you have to be familiar with Google Map services.
If you do not have enough time for that, you can have a look this PHP script. It is FREE and you can easily embed google maps on your PHP website. Also, it's possible to manage your maps without coding.

Google plus get Comments with PHP Code

I would like to read my Google Plus Feed with an php site and list all entrys in an array.... Now I found the explanation site of Google
https://developers.google.com/+/api/latest/comments/list
But I dont understand what I have to do?!? Can anybody give me a hint or an example, how to read my own newfeed from google + with an php coded site?
thank you in advance
regards Dennis
Well, I think it is better you to use the google-api-php-client which has methods to easily access content on Google Plus from PHP.
You may also want to check out the Google+ PHP Starter Project, which provides some configure and run code. One of the features demonstrated by this starter project is a list of your public activities.

How to use the Google SpreadSheets API to feed data to an application?

I've read through the Google Spreadsheets API PHP documentation. All examples are using Zend, which I cannot use. See this page: http://code.google.com/apis/spreadsheets/docs/1.0/developers_guide_php.html
Does anybody know a simple example of the following:
How can I use PHP w/ curl (or whatever) and the Google Spreadsheets API to get the data from a Google Spreadsheets Doc?
It's my understanding that the data will be delivered in XML format. From there, I'll use PHP to manipulate it.
Google is your friend! ;)
http://code.google.com/apis/gdata/articles/php_client_lib.html
http://sim.plified.com/2008/09/14/accessing-google-spreadsheet-with-php/
http://farinspace.com/2009/05/saving-form-data-to-google-spreadsheets/
From what I can see and how most of the other Google API work, the Spreadsheet API is centered around URLs. You formulate a URL and an xml response is returned. It seams that for this particular product however, most the support is for the Zend framewok implementation. You could always download the Zend component and reverse engineer it to work.
The Google Spreadsheets Data API is documented here.
http://code.google.com/apis/spreadsheets/docs/1.0/developers_guide_protocol.html
It's a REST API so you just need appropriately formatted GETS and POSTS as described in the docs.
The Zend Gdata implementation is the official PHP library for Google APIs. Not much of an answer I guess but I have to ask, why wouldn't you just use it? (It seems like you're reinventing the wheel... :-)

Categories