-3
내가 file_get_content와 컬을 교체해야
와 컬 교체 (I 민감한 정보를 삭제 한) : 가 file_get_content
curl -F 'client_id=aaa' \
-F 'client_secret=bbb' \
-F 'grant_type=authorization_code' \
-F 'redirect_uri=http://testtest.altervista.org/instagram/' \
-F 'code=ccc' \
https://api.instagram.com/oauth/access_token
내가 (이 아무것도 돌려주지 않는)이 있지만 넣은 사람은 아니다 일을 tryed :
$url = 'https://api.instagram.com/oauth/access_token?client_id=aaa&client_secret=bbb&grant_type=authorization_code&redirect_uri=http://testtest.altervista.org/instagram/&code=ccc';
print json_decode(file_get_contents($url));
왜 ?
브라우저에서이 URL을 실행할 때 무엇을 얻고 있습니까? – Exception
당신은 'shell'cURL 명령을 PHP file_get_contents로 대체하고 있습니다 ... 여기서 당신의 진정한 목표는 무엇입니까? – YvesLeBorg
URL 안에 URL이있을 때 내부 URL은 반드시'urlencode()'되어야합니다. 아무 것도 얻지 못하면 오류 로그 또는 적어도 호출에 의해 반환 된 헤더와 상태 코드를 표시하는 것이 도움이됩니다. – DanFromGermany