mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-04-02 01:52:10 +09:00
FileHandler::getRemoteResource() 에서 301, 302 redirect header처리 시점을 변경하여 정상적으로 데이터를 획득하도록 수정
git-svn-id: http://xe-core.googlecode.com/svn/sandbox@6097 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
2686e16e8f
commit
8d00b2f33f
1 changed files with 1 additions and 2 deletions
|
|
@ -295,13 +295,12 @@
|
|||
}
|
||||
|
||||
$oResponse = $oRequest->sendRequest();
|
||||
if(PEAR::isError($oResponse)) return;
|
||||
|
||||
$code = $oRequest->getResponseCode();
|
||||
$header = $oRequest->getResponseHeader();
|
||||
$body = $oRequest->getResponseBody();
|
||||
|
||||
if($code == 301) {
|
||||
if($code == 301 || $code == 302) {
|
||||
$url = $header['location'];
|
||||
if($url) return FileHandler::getRemoteResource($url, $body, $timeout, $method, $content_type, $headers);
|
||||
else return;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue