Looking at http://instagram.com/developer/authentication/ - The recommended way of communication is serverside.
I understand how I do step1 and step2. But in step3 they want me POST data directly serverside? (I understand how I could do a post request from jQuery) But is it even possible to do directly from PHP/CodeIgniter?
This is basically step3:
In the previous step, you’ll have received a code which you’ll have to exchange in order to receive an access_token for the user. In order to make this exchange, you simply have to POST this code, along with some app identification parameters to our access_token endpoint.
I have all this info: (from response from Instagram)
client_id: your client id
client_secret: your client secret
grant_type: authorization_code is currently the only supported value
redirect_uri: the redirect_uri you used in the authorization request. Note: this has to be the same value as in the authorization request.
code: the exact code you received during the authorization step.