mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-07 02:31:40 +09:00
원격 파일 다운로드 받을때 한글명 파일을 제대로 받도록 수정
git-svn-id: http://xe-core.googlecode.com/svn/sandbox@3968 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
6835a03b5f
commit
c02ee2a382
1 changed files with 4 additions and 1 deletions
|
|
@ -152,6 +152,7 @@
|
|||
if(!$fp) return;
|
||||
|
||||
// 한글 파일이 있으면 한글파일 부분만 urlencode하여 처리 (iconv 필수)
|
||||
/*
|
||||
$path = $url_info['path'];
|
||||
if(preg_match('/[\xEA-\xED][\x80-\xFF]{2}/', $path)&&function_exists('iconv')) {
|
||||
$path_list = explode('/',$path);
|
||||
|
|
@ -162,8 +163,10 @@
|
|||
$path = implode('/',$path_list);
|
||||
$url_info['path'] = $path;
|
||||
}
|
||||
*/
|
||||
|
||||
$header = sprintf("GET %s?%s HTTP/1.0\r\nHost: %s\r\nReferer: %s://%s\r\nRequestUrl: %s\r\nConnection: Close\r\n\r\n", $url_info['path'], $url_info['query'], $url_info['host'], $url_info['scheme'], $url_info['host'], Context::getRequestUri());
|
||||
$header = sprintf("GET %s%s HTTP/1.0\r\nHost: %s\r\nAccept-Charset: utf-8;q=0.7,*;q=0.7\r\nReferer: %s://%s\r\nRequestUrl: %s\r\nConnection: Close\r\n\r\n", $url_info['path'], $url_info['query']?'?'.$url_info['query']:'', $url_info['host'], $url_info['scheme'], $url_info['host'], Context::getRequestUri());
|
||||
debugPrint($header);
|
||||
|
||||
@fwrite($fp, $header);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue