2016-03-28 88 views
0

我已經註冊redirect_uriInstagram的API - 重定向URI

http://localhost/auth.php 

而且我請求

http://api.instagram.com/oauth/authorize/?client_id=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&response_type=code&scope=public_content&redirect_uri=http://localhost/auth.php? type=like&ltse=1 

那我收回這個從Instagram的:

localhost/auth.php?type=like&code=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX 

但我需要兩個URI中的參數(類型和ltse): 像這樣:

localhost/auth.php?type=like&ltse=1&code=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX 

什麼是錯誤的,我的要求嗎?

回答

0

嘗試使用 http://api.instagram.com/oauth/authorize/?client_id=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&response_type=code&scope=public_content&類型=像& ltse = 1 & REDIRECT_URI = http://localhost/auth.php

或可以傳入 「狀態」 的值。狀態總是與代碼

+0

我試過了,沒有效果我有這個 HTTP返回://localhost/auth.php碼= XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX 你的方法這個狀態工作正常,但我想給我的自己的參數。 http://localhost/auth.php?ltse = 1&code = XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&state = somevalue –

+0

這是一個意見。編碼「&type = like&ltse = 1」併發出以下請求 http://api.instagram.com/oauth/authorize/?client_id=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&response_type=code&scope=public_content&STATE=ENCODED_VALUE&redirect_uri=http://localhost/auth.php – Rajat