#14 별도의 외부 페이지(opage) 모듈을 만들어서 외부 html/php 문서나 외부 html문서등을 내부에서 사용할 수 있는 모듈 제작

git-svn-id: http://xe-core.googlecode.com/svn/sandbox@2600 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
zero 2007-09-18 04:13:34 +00:00
parent 7f90125627
commit dc24001d46
21 changed files with 984 additions and 4 deletions

View file

@ -336,13 +336,14 @@
$flag = true;
foreach($obj as $key=>$val) {
if(!$val) continue;
if($val && !iconv($charset,'UTF-8',$val)) $flag = false;
if($val && iconv($charset,$charset,$val)!=$val) $flag = false;
}
if($flag == true) {
foreach($obj as $key => $val) $obj->{$key} = iconv($charset,'UTF-8',$val);
return $obj;
}
}
return $obj;
}
/**
@ -868,7 +869,7 @@
function _transEditorComponent($matches) {
// IE에서는 태그의 특성중에서 " 를 빼어 버리는 경우가 있기에 정규표현식으로 추가해줌
$buff = $matches[0];
$buff = preg_replace_callback('/([^=^"^ ]*)=([^ ]*)/i', array($this, _fixQuotation), $buff);
$buff = preg_replace_callback('/([^=^"^ ]*)=([^ ^>]*)/i', array($this, _fixQuotation), $buff);
$buff = str_replace("&","&",$buff);
// 위젯에서 생성된 코드 (img, div태그내에 editor_widget코드 존재)의 parameter를 추출

View file

@ -133,6 +133,7 @@
$url_info = parse_url($url);
if(!$url_info['port']) $url_info['port'] = 80;
if(!$url_info['path']) $url_info['path'] = '/';
$fp = @fsockopen($url_info['host'], $url_info['port']);
if(!$fp) return;
@ -149,7 +150,7 @@
$url_info['path'] = $path;
}
$header = sprintf("GET %s HTTP/2.0\r\nHost: %s\r\nReferer: %s://%s\r\nRequestUrl: %s\r\nConnection: Close\r\n\r\n", $url_info['path'], $url_info['host'], $url_info['scheme'], $url_info['host'], Context::getRequestUri());
$header = sprintf("GET %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['host'], $url_info['scheme'], $url_info['host'], Context::getRequestUri());
@fwrite($fp, $header);