cheidtor 제거

This commit is contained in:
gnuboard
2012-12-31 10:40:36 +09:00
parent 55f2cb1bdd
commit 37f4b5feb5
202 changed files with 126 additions and 9022 deletions

View File

@ -1,56 +0,0 @@
<?
if (!defined('_GNUBOARD_')) exit;
if ($g4['is_cheditor5'])
{
$g4['cheditor4'] = 'cheditor5';
$g4['cheditor4_path'] = $g4['path'] . '/' . $g4['cheditor4'];
function cheditor1($id, $width='100%', $height='250')
{
global $g4;
return "
<script>
var ed_{$id} = new cheditor('ed_{$id}');
ed_{$id}.config.editorHeight = '{$height}';
ed_{$id}.config.editorWidth = '{$width}';
ed_{$id}.inputForm = 'tx_{$id}';
</script>";
}
}
else
{
function cheditor1($id, $width='100%', $height='250')
{
global $g4;
return "
<script>
var ed_{$id} = new cheditor('ed_{$id}');
ed_{$id}.config.editorHeight = '{$height}';
ed_{$id}.config.editorWidth = '{$width}';
ed_{$id}.config.imgReSize = false;
ed_{$id}.config.fullHTMLSource = false;
ed_{$id}.config.editorPath = '{$g4[cheditor4_path]}';
ed_{$id}.inputForm = 'tx_{$id}';
</script>";
}
}
function cheditor2($id, $content='')
{
global $g4;
return "
<textarea name='{$id}' id='tx_{$id}' style='display:none;'>{$content}</textarea>
<script>
ed_{$id}.run();
</script>";
}
function cheditor3($id)
{
return "document.getElementById('tx_{$id}').value = ed_{$id}.outputBodyHTML();";
}
?>

View File

@ -1540,4 +1540,24 @@ function is_utf8($str)
}
return true;
}
/*
-----------------------------------------------------------
Charset 을 변환하는 함수
-----------------------------------------------------------
iconv 함수가 있으면 iconv 로 변환하고
없으면 mb_convert_encoding 함수를 사용한다.
둘다 없으면 사용할 수 없다.
*/
function convert_charset($from_charset, $to_charset, $str)
{
if( function_exists('iconv') )
return iconv($from_charset, $to_charset, $str);
elseif( function_exists('mb_convert_encoding') )
return mb_convert_encoding($str, $to_charset, $from_charset);
else
die("Not found 'iconv' or 'mbstring' library in server.");
}
?>