qmail등 비표준 개행문자 사용 mta를 지원하기 위한 qmail_compatibility 변수를 db.config.php에 추가하고 관리자 페이지에서 설정토록 함

git-svn-id: http://xe-core.googlecode.com/svn/sandbox@4153 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
mmx900 2008-04-27 15:38:42 +00:00
parent c6815f9a1a
commit 93a6bd053c
6 changed files with 54 additions and 35 deletions

View file

@ -181,10 +181,13 @@
if(!$db_info->time_zone) $db_info->time_zone = date("O");
if(!$db_info->use_optimizer || $db_info->use_optimizer != 'N') $db_info->use_optimizer = 'Y';
else $db_info->use_optimizer = 'N';
if(!$db_info->qmail_compatibility || $db_info->qmail_compatibility != 'Y') $db_info->qmail_compatibility = 'N';
else $db_info->qmail_compatibility = 'Y';
$this->_setDBInfo($db_info);
$GLOBALS['_time_zone'] = $db_info->time_zone;
$GLOBALS['_qmail_compatibility'] = $db_info->qmail_compatibility;
}
/**

View file

@ -63,25 +63,27 @@
function send() {
$boundary = '----=='.uniqid(rand(),true);
$eol = $GLOBALS['_qmail_compatibility'] == "Y" ? "\n" : "\r\n";
$headers = sprintf(
"From: %s\r\n".
"MIME-Version: 1.0\r\n".
"Content-Type: multipart/alternative;\r\n\tboundary=\"%s\"\r\n\r\n".
"From: %s".$eol.
"MIME-Version: 1.0".$eol.
"Content-Type: multipart/alternative;".$eol."\tboundary=\"%s\"".$eol.$eol.
"",
$this->getSender(),
$boundary
);
$body = sprintf(
"--%s\r\n".
"Content-Type: text/plain; charset=utf-8; format=flowed\r\n".
"Content-Transfer-Encoding: base64\r\n".
"Content-Disposition: inline\r\n\r\n".
"--%s".$eol.
"Content-Type: text/plain; charset=utf-8; format=flowed".$eol.
"Content-Transfer-Encoding: base64".$eol.
"Content-Disposition: inline".$eol.$eol.
"%s".
"--%s\r\n".
"Content-Type: text/html; charset=utf-8\r\n".
"Content-Transfer-Encoding: base64\r\n".
"Content-Disposition: inline\r\n\r\n".
"--%s".$eol.
"Content-Type: text/html; charset=utf-8".$eol.
"Content-Transfer-Encoding: base64".$eol.
"Content-Disposition: inline".$eol.$eol.
"%s".
"--%s--".
"",

View file

@ -39,6 +39,7 @@
Context::set('time_zone', $GLOBALS['_time_zone']);
Context::set('use_rewrite', $db_info->use_rewrite=='Y'?'Y':'N');
Context::set('use_optimizer', $db_info->use_optimizer!='N'?'Y':'N');
Context::set('qmail_compatibility', $db_info->qmail_compatibility=='Y'?'Y':'N');
Context::setBrowserTitle("ZeroboardXE Admin Page");
}

View file

@ -75,6 +75,13 @@
<p>{$lang->about_time_zone}</p>
</td>
</tr>
<tr>
<th scope="row">{$lang->qmail_compatibility}</th>
<td>
<input type="checkbox" name="qmail_compatibility" value="Y" <!--@if($qmail_compatibility=='Y')-->checked="checked"<!--@end--> />
<p>{$lang->about_qmail_compatibility}</p>
</td>
</tr>
<tr>
<th colspan="2" class="button">
<span class="button"><input type="button" value="{$lang->cmd_remake_cache}" onclick="doRecompileCacheFile(); return false;"/></span>

View file

@ -53,8 +53,12 @@
$time_zone = Context::get('time_zone');
$qmail_compatibility = Context::get('qmail_compatibility');
if($qmail_compatibility!='Y') $qmail_compatibility = 'N';
$db_info = Context::getDBInfo();
$db_info->time_zone = $time_zone;
$db_info->qmail_compatibility = $qmail_compatibility;
$db_info->use_rewrite = $use_rewrite;
$db_info->use_optimizer = $use_optimizer;
$db_info->lang_type = Context::getLangType();

View file

@ -261,6 +261,8 @@ EndOfLicense;
$lang->about_rewrite = '웹서버에서 rewrite mod를 지원하면 http://주소/?document_srl=123 같이 복잡한 주소를 http://주소/123과 같이 간단하게 줄일 수 있습니다.';
$lang->time_zone = 'time zone';
$lang->about_time_zone = '서버의 설정시간과 사용하려는 장소의 시간이 차이가 날 경우 time zone을 지정하시면 표시되는 시간을 지정된 곳의 시간으로 사용하실 수 있습니다';
$lang->qmail_compatibility = 'Qmail 호환';
$lang->about_qmail_compatibility = 'Qmail등 CRLF를 줄 구분자로 인식하지 못하는 MTA에서 메일이 발송되도록 합니다.';
$lang->about_database_file = 'Sqlite는 파일에 데이터를 저장합니다. 데이터베이스 파일의 위치를 웹에서 접근할 수 없는 곳으로 하셔야 합니다<br/><span style="color:red">데이터 파일은 707퍼미션 설정된 곳으로 지정해주세요.</span>';