I am totally new to the twitter API, and I am trying to get all of my followers images to display them on my site, but the documentation on twitter.com has just confused me even more.
I am using PHP, and as far as I can tell I need to register an application, get a library that is suited to my needs, and them proceed to create my application.
The only problem with that is that I have no idea how to authenticate using OAuth, if anyone could shine some light on this matter, post a code snippit of how I can get all of the followers pics or maybe even point me to some useful tutorials or resources, that would be a great help.
Thanx in advance!
Everything you need to know is at the official Twitter API Docs at http://dev.twitter.com/doc
Like you already pointed out, you are supposed to get a library for interfacing with the Twitter API. These libraries usually have means to authenticate via OAuth as well, for instance you can use Zend Framework's Zend_OAuth component to authenticate and then use the access token to talk to the Twitter API with Zend_Service_Twitter.
Related
Is there any way to access Twitter analytics api and data with some kind of php library or something?
I want to access my own account data and I want to create a php app that allows me to get that data and show it in a different way (Html,Css).
I got my tweets and other stuff with his twitter API and with some libraries, but now I need to get data from twitter analytics.
I have read some topics about this in stackoverflow, but social media's api changes all the time and I want to know if it is possible to do this right now, or if someone has discovered a way to do it.
Thanks.
No API unfortunately, just a hackish way (Selenium) in Python that I created as a package.
$ pip install twitter-analytics
More here: https://github.com/philippe2803/twitter-analytics-wrapper
I know this subject has been done already over and over. but... i must be stupid so i'll try to figure out my problem simply.
I have a facebook page, let s say that one :
http://www.facebook.com/pages/Medieval-Forgecom/302734029745018
with a few fan poeple.
now on my website i would like to give a discount to poeple who are fan of that page.
So i tried the php api (with an application id and secret) before discovering that this is NOT what i want as my page is not an app and has no appId neither secret. Am i misunderstanding something here?
So i m wondering how in php i can know if someone is fan or not...
If it is not possible i could use the javascript api to make this check ( wich is quite bad, it should be done somewhere via php) but even this way i get trouble with the deprecated api and the code refering to javascript inside the facebook website.
in a nutshell, i'm lost.
thanks for your time and attention.
Do some research on the concept of "fan-gate". I think this is what you're looking for.
https://www.facebook.com/note.php?note_id=10150130919053430
http://www.youtube.com/watch?v=fBBnrtG0hAw
There are three ways of using Facebook API. Social plugins are widgets such as comments or like buttons. You can put them into your site directly and easily. And then there is the Graph API. First way of using this API is to create a whole standalone Facebook application, such as Farmwille. Second way is to use it only at your site, out of the Facebook frame. Regardless of the type of your usage, you need to register an application on Facebook, so Facebook API can authorize you. Without that you can't use the API. You don't need to create a real standalone app if you want only to use the API at your own site, but you must register it and this registration is just called Facebook application. It can be virtual application representing your site.
I'm trying to find a service/script that allow me to add login to Facebook, twitter, google... in one solution: i have tried Hibridauth but it doesn't work at least for me, i don't find tutorial for Facebook and openid and i don't want to use paid service or free but limited ones.
Do you know something good?
I've heard good things about Zend_Oauth
Check this Links you may find a solution
PHP OpenID Library that allows facebook
Getting Started with OpenID and PHP
Open id and facebook implementation in php
I am not sure about it but i have read this in a comment on a blog The comment is "Check out NinjAuth which is currently a Fuel package. You can find the repo here https://github.com/philsturgeon/fuel-ninjauth and description here http://philsturgeon.co.uk/blog/2011/09/ninjauth-social-integration-php"
I was reading some stuff about the YQL api that Yahoo! has provided, I am not sure, but it appears to be a collection of lots of third party api into one common language, right?
what I don't get is how to make the facebook login through it so I can get the user profile data...
My project is to add a facebook(and other social networks) form login, because the website won't have his own login, people will have to use a social network to link in. Then I thought the YQL would help me out with this task so I wouldn't have to develop lots of functions to each one of the networks.
Reading this http://developer.yahoo.com/yql/guide/yql-code-examples.html#sdk_yql, I understood how to make a Yahoo login so I can access some private data, but couldn't find how I could do it with facebook and others
So my question... Can YQL help me with this? Can you give me a simple example of a facebook session using it within PHP? Are there alternatives to aid me in this task?
thanks,
Jonathan
Yes , using YQL you will be able to do this task .. you can look at this demo http://demo.tutorialzine.com/2010/05/showing-facebook-twitter-rss-stats-jquery-yql/demo.html. Also if you are going to only use Facebook authentication , then there is no need for YQL you can do it using http://developers.facebook.com/docs/authentication/
I highly doubt that YQL has an API that gives a free hand with facebook login. You have to consider how a login works. You send POST data to a web server containing client-side password hashes and encryptions, as well as other kinds of identification. YQL has no way to "standardize" logins - it would have to make a new API for every popular web site.
I have noticed some Twitter Applications manage to get a particular users Location, Name, Profile Image etc using just the twitter username?
Hows is this possible?
I ask because I have not come across any where in the Twitter docs on how you can do this. I can get a users details myself using oAuth when the user provides my app permission but thats it.
Would be grateful if this could be cleared. I hope its not the use of CURL as this is not a good idea in my eyes. If there is another way, is there a PHP implementation that I could use.
Thank you for any help.
Update
I did not know that existed! Is there a PHP wrapper or class someone has written to use that ? Sorry, I am complete noob and I relay on wrappers and simple function calls!
It's returned by the users/show call from the API.
For example:
http://twitter.com/users/show.xml?screen_name=dougw
The API wiki lists a PHP library FWIW.