Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2579323ddf | ||
|
|
2658dde159 | ||
|
|
d9b8d31225 | ||
|
|
4d8500be02 | ||
|
|
288da7f9e1 |
@@ -10,3 +10,4 @@ cheditor*/
|
||||
ckeditor43/
|
||||
log/
|
||||
g5_tree/
|
||||
naver*.html
|
||||
|
||||
@@ -10,7 +10,6 @@ $menu['menu100'] = array (
|
||||
array('100900', '캐시파일 일괄삭제',G5_ADMIN_URL.'/cache_file_delete.php', 'cf_cache', 1),
|
||||
array('100910', '캡챠파일 일괄삭제',G5_ADMIN_URL.'/captcha_file_delete.php', 'cf_captcha', 1),
|
||||
array('100920', '썸네일파일 일괄삭제',G5_ADMIN_URL.'/thumbnail_file_delete.php', 'cf_thumbnail', 1),
|
||||
array('100930', '네이버 신디케이션 핑',G5_SYNDI_URL.'/ping.php', 'cf_syndi_ping', 1),
|
||||
array('100500', 'phpinfo()', G5_ADMIN_URL.'/phpinfo.php', 'cf_phpinfo')
|
||||
);
|
||||
?>
|
||||
@@ -30,8 +30,4 @@ delete_cache_latest($tmp_bo_table);
|
||||
|
||||
// 게시판 폴더 전체 삭제
|
||||
rm_rf(G5_DATA_PATH.'/file/'.$tmp_bo_table);
|
||||
|
||||
// syndication ping
|
||||
if(G5_SYNDI_USE)
|
||||
include G5_SYNDI_PATH.'/include/include.adm.board_delete.inc.php';
|
||||
?>
|
||||
@@ -385,9 +385,5 @@ if ($all_fields) {
|
||||
|
||||
delete_cache_latest($bo_table);
|
||||
|
||||
// syndication ping
|
||||
if(G5_SYNDI_USE)
|
||||
include G5_SYNDI_PATH.'/include/include.adm.board_form_update.php';
|
||||
|
||||
goto_url("./board_form.php?w=u&bo_table={$bo_table}&{$qstr}");
|
||||
?>
|
||||
|
||||
@@ -65,9 +65,5 @@ if ($w == '') {
|
||||
alert('제대로 된 값이 넘어오지 않았습니다.');
|
||||
}
|
||||
|
||||
// syndication ping
|
||||
if(G5_SYNDI_USE)
|
||||
include G5_SYNDI_PATH.'/include/include.adm.boardgroup_form_update.php';
|
||||
|
||||
goto_url('./boardgroup_form.php?w=u&gr_id='.$gr_id.'&'.$qstr);
|
||||
?>
|
||||
|
||||
@@ -130,6 +130,16 @@ if(!isset($config['cf_add_meta'])) {
|
||||
ADD `cf_add_meta` TEXT NOT NULL AFTER `cf_analytics` ", true);
|
||||
}
|
||||
|
||||
if (!isset($config['cf_syndi_token'])) {
|
||||
sql_query(" ALTER TABLE `{$g5['config_table']}`
|
||||
ADD `cf_syndi_token` VARCHAR(255) NOT NULL AFTER `cf_add_meta` ", true);
|
||||
}
|
||||
|
||||
if (!isset($config['cf_syndi_except'])) {
|
||||
sql_query(" ALTER TABLE `{$g5['config_table']}`
|
||||
ADD `cf_syndi_except` TEXT NOT NULL AFTER `cf_syndi_token` ", true);
|
||||
}
|
||||
|
||||
if(!isset($config['cf_sms_use'])) {
|
||||
sql_query(" ALTER TABLE `{$g5['config_table']}`
|
||||
ADD `cf_sms_use` varchar(255) NOT NULL DEFAULT '' AFTER `cf_cert_limit`,
|
||||
@@ -167,6 +177,12 @@ if(!isset($config['cf_optimize_date'])) {
|
||||
ADD `cf_optimize_date` date NOT NULL default '0000-00-00' AFTER `cf_popular_del` ", true);
|
||||
}
|
||||
|
||||
// 카카오톡링크 api 키
|
||||
if(!isset($config['cf_kakao_js_apikey'])) {
|
||||
sql_query(" ALTER TABLE `{$g5['config_table']}`
|
||||
ADD `cf_kakao_js_apikey` varchar(255) NOT NULL DEFAULT '' AFTER `cf_googl_shorturl_apikey` ", true);
|
||||
}
|
||||
|
||||
if(!$config['cf_faq_skin']) $config['cf_faq_skin'] = "basic";
|
||||
if(!$config['cf_mobile_faq_skin']) $config['cf_mobile_faq_skin'] = "basic";
|
||||
|
||||
@@ -503,6 +519,21 @@ if ($config['cf_icode_id'] && $config['cf_icode_pw']) {
|
||||
<textarea name="cf_add_meta" id="cf_add_meta"><?php echo $config['cf_add_meta']; ?></textarea>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row"><label for="cf_syndi_token">네이버 신디케이션 연동키</label></th>
|
||||
<td colspan="3">
|
||||
<?php if (!function_exists('curl_init')) echo help('<b>경고) curl이 지원되지 않아 네이버 신디케이션을 사용할수 없습니다.</b>'); ?>
|
||||
<?php echo help('네이버 신디케이션 연동키(token)을 입력하면 네이버 신디케이션을 사용할 수 있습니다.<br>연동키는 <a href="http://webmastertool.naver.com/" target="_blank"><u>네이버 웹마스터도구</u></a> -> 네이버 신디케이션에서 발급할 수 있습니다.') ?>
|
||||
<input type="text" name="cf_syndi_token" value="<?php echo $config['cf_syndi_token'] ?>" id="cf_syndi_token" class="frm_input" size="70">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row"><label for="cf_syndi_except">네이버 신디케이션 제외게시판</label></th>
|
||||
<td colspan="3">
|
||||
<?php echo help('네이버 신디케이션 수집에서 제외할 게시판 아이디를 | 로 구분하여 입력하십시오. 예) notice|adult<br>참고로 그룹접근사용 게시판, 글읽기 권한 2 이상 게시판, 비밀글은 신디케이션 수집에서 제외됩니다.') ?>
|
||||
<input type="text" name="cf_syndi_except" value="<?php echo $config['cf_syndi_except'] ?>" id="cf_syndi_except" class="frm_input" size="70">
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
@@ -1031,6 +1062,10 @@ if ($config['cf_icode_id'] && $config['cf_icode_pw']) {
|
||||
<td>
|
||||
<input type="text" name="cf_googl_shorturl_apikey" value="<?php echo $config['cf_googl_shorturl_apikey'] ?>" id="cf_googl_shorturl_apikey" class="frm_input"> <a href="http://code.google.com/apis/console/" target="_blank" class="btn_frmline">API Key 등록하기</a>
|
||||
</td>
|
||||
<th scope="row"><label for="cf_kakao_js_apikey">카카오 Javascript API Key</label></th>
|
||||
<td>
|
||||
<input type="text" name="cf_kakao_js_apikey" value="<?php echo $config['cf_kakao_js_apikey'] ?>" id="cf_kakao_js_apikey" class="frm_input"> <a href="http://developers.kakao.com/" target="_blank" class="btn_frmline">앱 등록하기</a>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
@@ -53,6 +53,8 @@ $sql = " update {$g5['config_table']}
|
||||
cf_intercept_ip = '".trim($_POST['cf_intercept_ip'])."',
|
||||
cf_analytics = '{$_POST['cf_analytics']}',
|
||||
cf_add_meta = '{$_POST['cf_add_meta']}',
|
||||
cf_syndi_token = '{$_POST['cf_syndi_token']}',
|
||||
cf_syndi_except = '{$_POST['cf_syndi_except']}',
|
||||
cf_member_skin = '{$_POST['cf_member_skin']}',
|
||||
cf_use_homepage = '{$_POST['cf_use_homepage']}',
|
||||
cf_req_homepage = '{$_POST['cf_req_homepage']}',
|
||||
@@ -125,6 +127,7 @@ $sql = " update {$g5['config_table']}
|
||||
cf_icode_server_ip = '{$_POST['cf_icode_server_ip']}',
|
||||
cf_icode_server_port = '{$_POST['cf_icode_server_port']}',
|
||||
cf_googl_shorturl_apikey = '{$_POST['cf_googl_shorturl_apikey']}',
|
||||
cf_kakao_js_apikey = '{$_POST['cf_kakao_js_apikey']}',
|
||||
cf_facebook_appid = '{$_POST['cf_facebook_appid']}',
|
||||
cf_facebook_secret = '{$_POST['cf_facebook_secret']}',
|
||||
cf_twitter_key = '{$_POST['cf_twitter_key']}',
|
||||
|
||||
@@ -62,7 +62,7 @@ include_once('./admin.head.php');
|
||||
<tr>
|
||||
<th scope="row"><label for="mb_email">E-mail</label></th>
|
||||
<td>
|
||||
<?php echo help("메일 주소에 단어 포함 (예 : @sir.co.kr)") ?>
|
||||
<?php echo help("메일 주소에 단어 포함 (예 : @".preg_replace('#^(www[^\.]*\.){1}#', '', $_SERVER['HTTP_HOST']).")") ?>
|
||||
<input type="text" name="mb_email" value="<?php echo $mb_email ?>" id="mb_email" class="frm_input" size="50">
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
@@ -352,8 +352,8 @@ this.form.mb_intercept_date.value=this.form.mb_intercept_date.defaultValue; }">
|
||||
<script>
|
||||
function fmember_submit(f)
|
||||
{
|
||||
if (!f.mb_icon.value.match(/\.(gif|jp['e']g|png)$/i) && f.mb_icon.value) {
|
||||
alert('아이콘이 이미지 파일이 아닙니다. (bmp 제외)');
|
||||
if (!f.mb_icon.value.match(/\.gif$/i) && f.mb_icon.value) {
|
||||
alert('아이콘은 gif 파일만 가능합니다.');
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -43,7 +43,7 @@ if($error) {
|
||||
alert("<?php echo strip_tags($msg); ?>");
|
||||
//document.location.href = "<?php echo $url; ?>";
|
||||
<?php if ($url) { ?>
|
||||
document.location.replace("<?php echo $url; ?>");
|
||||
document.location.replace("<?php echo str_replace('&', '&', $url); ?>");
|
||||
<?php } else { ?>
|
||||
//alert('history.back();');
|
||||
history.back();
|
||||
|
||||
@@ -93,10 +93,6 @@ while ($row = sql_fetch_array($result))
|
||||
// 파일테이블 행 삭제
|
||||
sql_query(" delete from {$g5['board_file_table']} where bo_table = '$bo_table' and wr_id = '{$row['wr_id']}' ");
|
||||
|
||||
// syndication ping
|
||||
if(G5_SYNDI_USE)
|
||||
include G5_SYNDI_PATH.'/include/include.bbs.delete.php';
|
||||
|
||||
$count_write++;
|
||||
}
|
||||
else
|
||||
|
||||
@@ -106,10 +106,6 @@ for ($i=count($tmp_array)-1; $i>=0; $i--)
|
||||
// 파일테이블 행 삭제
|
||||
sql_query(" delete from {$g5['board_file_table']} where bo_table = '$bo_table' and wr_id = '{$row['wr_id']}' ");
|
||||
|
||||
// syndication ping
|
||||
if(G5_SYNDI_USE)
|
||||
include G5_SYNDI_PATH.'/include/include.bbs.delete_all.php';
|
||||
|
||||
$count_write++;
|
||||
}
|
||||
else
|
||||
|
||||
@@ -16,7 +16,7 @@ $sql = " update {$g5['member_table']} set mb_leave_date = '{$date}' where mb_id
|
||||
sql_query($sql);
|
||||
|
||||
// 3.09 수정 (로그아웃)
|
||||
session_unregister("ss_mb_id");
|
||||
unset($_SESSION['ss_mb_id']);
|
||||
|
||||
if (!$url)
|
||||
$url = G5_URL;
|
||||
|
||||
@@ -195,10 +195,6 @@ if ($sw == 'move')
|
||||
sql_query(" update {$g5['board_table']} set bo_count_write = bo_count_write - '$save_count_write', bo_count_comment = bo_count_comment - '$save_count_comment' where bo_table = '$bo_table' ");
|
||||
}
|
||||
|
||||
// syndication ping
|
||||
if(G5_SYNDI_USE)
|
||||
include G5_SYNDI_PATH.'/include/include.bbs.move_update.php';
|
||||
|
||||
$msg = '해당 게시물을 선택한 게시판으로 '.$act.' 하였습니다.';
|
||||
$opener_href = './board.php?bo_table='.$bo_table.'&page='.$page.'&'.$qstr;
|
||||
|
||||
|
||||
@@ -26,6 +26,15 @@ switch ($w) {
|
||||
$return_url = './board.php?bo_table='.$bo_table;
|
||||
}
|
||||
break;
|
||||
case 'sc' :
|
||||
// 비밀번호 창에서 로그인 하는 경우 관리자 또는 자신의 글이면 바로 글보기로 감
|
||||
if ($is_admin || ($member['mb_id'] == $write['mb_id'] && $write['mb_id']))
|
||||
goto_url('./board.php?bo_table='.$bo_table.'&wr_id='.$wr_id);
|
||||
else {
|
||||
$action = './password_check.php';
|
||||
$return_url = './board.php?bo_table='.$bo_table.'&wr_id='.$wr_id;
|
||||
}
|
||||
break;
|
||||
default :
|
||||
alert('w 값이 제대로 넘어오지 않았습니다.');
|
||||
}
|
||||
|
||||
@@ -15,6 +15,19 @@ if ($w == 's') {
|
||||
//set_session("ss_secret", "$bo_table|$wr[wr_num]");
|
||||
set_session($ss_name, TRUE);
|
||||
|
||||
} else if ($w == 'sc') {
|
||||
$qstr = 'bo_table='.$bo_table.'&sfl='.$sfl.'&stx='.$stx.'&sop='.$sop.'&wr_id='.$wr_id.'&page='.$page;
|
||||
|
||||
$wr = get_write($write_table, $wr_id);
|
||||
|
||||
if (sql_password($wr_password) != $wr['wr_password'])
|
||||
alert('비밀번호가 틀립니다.');
|
||||
|
||||
// 세션에 아래 정보를 저장. 하위번호는 비밀번호없이 보아야 하기 때문임.
|
||||
$ss_name = 'ss_secret_comment_'.$bo_table.'_'.$wr['wr_id'];
|
||||
//set_session("ss_secret", "$bo_table|$wr[wr_num]");
|
||||
set_session($ss_name, TRUE);
|
||||
|
||||
} else
|
||||
alert('w 값이 제대로 넘어오지 않았습니다.');
|
||||
|
||||
|
||||
@@ -83,7 +83,7 @@ if ($w == '' || $w == 'u') {
|
||||
|
||||
// 본인확인 체크
|
||||
if($config['cf_cert_use'] && $config['cf_cert_req']) {
|
||||
if(trim($_POST['cert_no']) != $_SESSION['ss_cert_no'])
|
||||
if(trim($_POST['cert_no']) != $_SESSION['ss_cert_no'] || !$_SESSION['ss_cert_no'])
|
||||
alert("회원가입을 위해서는 본인확인을 해주셔야 합니다.");
|
||||
}
|
||||
|
||||
|
||||
@@ -49,6 +49,15 @@ for ($i=0; $row=sql_fetch_array($result); $i++)
|
||||
$list[$i]['content1'] = $row['wr_content'];
|
||||
$list[$i]['content'] = conv_content($row['wr_content'], 0, 'wr_content');
|
||||
$list[$i]['content'] = search_font($stx, $list[$i]['content']);
|
||||
} else {
|
||||
$ss_name = 'ss_secret_comment_'.$bo_table.'_'.$list[$i]['wr_id'];
|
||||
|
||||
if(!get_session($ss_name))
|
||||
$list[$i]['content'] = '<a href="./password.php?w=sc&bo_table='.$bo_table.'&wr_id='.$list[$i]['wr_id'].$qstr.'" class="s_cmt">댓글내용 확인</a>';
|
||||
else {
|
||||
$list[$i]['content'] = conv_content($row['wr_content'], 0, 'wr_content');
|
||||
$list[$i]['content'] = search_font($stx, $list[$i]['content']);
|
||||
}
|
||||
}
|
||||
|
||||
$list[$i]['datetime'] = substr($row['wr_datetime'],2,14);
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
<?php
|
||||
include_once('./_common.php');
|
||||
include_once(G5_LIB_PATH.'/naver_syndi.lib.php');
|
||||
include_once(G5_CAPTCHA_PATH.'/captcha.lib.php');
|
||||
|
||||
$g5['title'] = '게시글 저장';
|
||||
@@ -9,6 +10,7 @@ $msg = array();
|
||||
$wr_subject = '';
|
||||
if (isset($_POST['wr_subject'])) {
|
||||
$wr_subject = substr(trim($_POST['wr_subject']),0,255);
|
||||
$wr_subject = preg_replace("#[\\\]+$#", "", $wr_subject);
|
||||
}
|
||||
if ($wr_subject == '') {
|
||||
$msg[] = '<strong>제목</strong>을 입력하세요.';
|
||||
@@ -476,9 +478,10 @@ if ($w == '' || $w == 'r') {
|
||||
sql_query(" update {$g5['board_table']} set bo_notice = '{$bo_notice}' where bo_table = '{$bo_table}' ");
|
||||
}
|
||||
|
||||
// syndication ping
|
||||
if(G5_SYNDI_USE)
|
||||
include G5_SYNDI_PATH.'/include/include.bbs.write_update.php';
|
||||
// 게시판그룹접근사용을 하지 않아야 하고 비회원 글읽기가 가능해야 하며 비밀글이 아니어야 합니다.
|
||||
if (!$group['gr_use_access'] && $board['bo_read_level'] < 2 && !$secret) {
|
||||
naver_syndi_ping($bo_table, $wr_id);
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
// 가변 파일 업로드
|
||||
|
||||
@@ -25,14 +25,6 @@ for ($i=0; $i<$ext_cnt; $i++) {
|
||||
}
|
||||
//==========================================================================================================================
|
||||
|
||||
// 완두콩님이 알려주신 보안관련 오류 수정
|
||||
// $member 에 값을 직접 넘길 수 있음
|
||||
$config = array();
|
||||
$member = array();
|
||||
$board = array();
|
||||
$group = array();
|
||||
$g5 = array();
|
||||
|
||||
|
||||
function g5_path()
|
||||
{
|
||||
@@ -54,6 +46,77 @@ include_once($g5_path['path'].'/config.php'); // 설정 파일
|
||||
unset($g5_path);
|
||||
|
||||
|
||||
// multi-dimensional array에 사용자지정 함수적용
|
||||
function array_map_deep($fn, $array)
|
||||
{
|
||||
if(is_array($array)) {
|
||||
foreach($array as $key => $value) {
|
||||
if(is_array($value)) {
|
||||
$array[$key] = array_map_deep($fn, $value);
|
||||
} else {
|
||||
$array[$key] = call_user_func($fn, $value);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$array = call_user_func($fn, $array);
|
||||
}
|
||||
|
||||
return $array;
|
||||
}
|
||||
|
||||
|
||||
// SQL Injection 대응 문자열 필터링
|
||||
function sql_escape_string($str)
|
||||
{
|
||||
if(defined('G5_ESCAPE_PATTERN') && defined('G5_ESCAPE_REPLACE')) {
|
||||
$pattern = G5_ESCAPE_PATTERN;
|
||||
$replace = G5_ESCAPE_REPLACE;
|
||||
|
||||
if($pattern)
|
||||
$str = preg_replace($pattern, $replace, $str);
|
||||
}
|
||||
|
||||
$str = call_user_func('addslashes', $str);
|
||||
|
||||
return $str;
|
||||
}
|
||||
|
||||
|
||||
//==============================================================================
|
||||
// SQL Injection 등으로 부터 보호를 위해 sql_escape_string() 적용
|
||||
//------------------------------------------------------------------------------
|
||||
// magic_quotes_gpc 에 의한 backslashes 제거
|
||||
if (get_magic_quotes_gpc()) {
|
||||
$_POST = array_map_deep('stripslashes', $_POST);
|
||||
$_GET = array_map_deep('stripslashes', $_GET);
|
||||
$_COOKIE = array_map_deep('stripslashes', $_COOKIE);
|
||||
$_REQUEST = array_map_deep('stripslashes', $_REQUEST);
|
||||
}
|
||||
|
||||
// sql_escape_string 적용
|
||||
$_POST = array_map_deep(G5_ESCAPE_FUNCTION, $_POST);
|
||||
$_GET = array_map_deep(G5_ESCAPE_FUNCTION, $_GET);
|
||||
$_COOKIE = array_map_deep(G5_ESCAPE_FUNCTION, $_COOKIE);
|
||||
$_REQUEST = array_map_deep(G5_ESCAPE_FUNCTION, $_REQUEST);
|
||||
//==============================================================================
|
||||
|
||||
|
||||
// PHP 4.1.0 부터 지원됨
|
||||
// php.ini 의 register_globals=off 일 경우
|
||||
@extract($_GET);
|
||||
@extract($_POST);
|
||||
@extract($_SERVER);
|
||||
|
||||
|
||||
// 완두콩님이 알려주신 보안관련 오류 수정
|
||||
// $member 에 값을 직접 넘길 수 있음
|
||||
$config = array();
|
||||
$member = array();
|
||||
$board = array();
|
||||
$group = array();
|
||||
$g5 = array();
|
||||
|
||||
|
||||
//==============================================================================
|
||||
// 공통
|
||||
//------------------------------------------------------------------------------
|
||||
@@ -71,30 +134,6 @@ if (file_exists($dbconfig_file)) {
|
||||
sql_query(" set names utf8 ");
|
||||
if(defined('G5_MYSQL_SET_MODE') && G5_MYSQL_SET_MODE) sql_query("SET SESSION sql_mode = ''");
|
||||
if (defined(G5_TIMEZONE)) sql_query(" set time_zone = '".G5_TIMEZONE."'");
|
||||
|
||||
//==============================================================================
|
||||
// SQL Injection 등으로 부터 보호를 위해 sql_escape_string() 적용
|
||||
//------------------------------------------------------------------------------
|
||||
// magic_quotes_gpc 에 의한 backslashes 제거
|
||||
if (get_magic_quotes_gpc()) {
|
||||
$_POST = array_map_deep('stripslashes', $_POST);
|
||||
$_GET = array_map_deep('stripslashes', $_GET);
|
||||
$_COOKIE = array_map_deep('stripslashes', $_COOKIE);
|
||||
$_REQUEST = array_map_deep('stripslashes', $_REQUEST);
|
||||
}
|
||||
|
||||
// sql_escape_string 적용
|
||||
$_POST = array_map_deep(G5_ESCAPE_FUNCTION, $_POST);
|
||||
$_GET = array_map_deep(G5_ESCAPE_FUNCTION, $_GET);
|
||||
$_COOKIE = array_map_deep(G5_ESCAPE_FUNCTION, $_COOKIE);
|
||||
$_REQUEST = array_map_deep(G5_ESCAPE_FUNCTION, $_REQUEST);
|
||||
//==============================================================================
|
||||
|
||||
// PHP 4.1.0 부터 지원됨
|
||||
// php.ini 의 register_globals=off 일 경우
|
||||
@extract($_GET);
|
||||
@extract($_POST);
|
||||
@extract($_SERVER);
|
||||
} else {
|
||||
?>
|
||||
|
||||
|
||||
@@ -117,7 +117,6 @@ define('G5_PHPMAILER_PATH', G5_PLUGIN_PATH.'/'.G5_PHPMAILER_DIR);
|
||||
|
||||
define('G5_USE_MOBILE', true); // 모바일 홈페이지를 사용하지 않을 경우 false 로 설정
|
||||
define('G5_USE_CACHE', true); // 최신글등에 cache 기능 사용 여부
|
||||
define('G5_SYNDI_USE', true); // Syndication 기능 사용 여부
|
||||
|
||||
|
||||
/********************
|
||||
@@ -162,8 +161,12 @@ define('G5_SMTP', '127.0.0.1');
|
||||
define('G5_DISPLAY_SQL_ERROR', TRUE);
|
||||
|
||||
// escape string 처리 함수 지정
|
||||
// POST 등에서 한글이 깨질 경우 addslashes 로 변경
|
||||
define('G5_ESCAPE_FUNCTION', 'sql_real_escape_string');
|
||||
// addslashes 로 변경 가능
|
||||
define('G5_ESCAPE_FUNCTION', 'sql_escape_string');
|
||||
|
||||
// sql_escape_string 함수에서 사용될 패턴
|
||||
//define('G5_ESCAPE_PATTERN', '/(and|or).*(union|select|insert|update|delete|from|where|limit|create|drop).*/i');
|
||||
//define('G5_ESCAPE_REPLACE', '');
|
||||
|
||||
// 게시판에서 링크의 기본개수를 말합니다.
|
||||
// 필드를 추가하면 이 숫자를 필드수에 맞게 늘려주십시오.
|
||||
|
||||
@@ -294,6 +294,7 @@ CREATE TABLE IF NOT EXISTS `g5_config` (
|
||||
`cf_facebook_secret` varchar(255) NOT NULL,
|
||||
`cf_twitter_key` varchar(255) NOT NULL,
|
||||
`cf_twitter_secret` varchar(255) NOT NULL,
|
||||
`cf_kakao_js_apikey` varchar(255) NOT NULL,
|
||||
`cf_1_subj` varchar(255) NOT NULL DEFAULT '',
|
||||
`cf_2_subj` varchar(255) NOT NULL DEFAULT '',
|
||||
`cf_3_subj` varchar(255) NOT NULL DEFAULT '',
|
||||
@@ -664,22 +665,6 @@ CREATE TABLE IF NOT EXISTS `g5_uniqid` (
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `g5_syndi_log`
|
||||
--
|
||||
|
||||
DROP TABLE IF EXISTS `g5_syndi_log`;
|
||||
CREATE TABLE IF NOT EXISTS `g5_syndi_log` (
|
||||
`content_id` int(11) NOT NULL,
|
||||
`bbs_id` varchar(50) NOT NULL,
|
||||
`title` text NOT NULL,
|
||||
`link_alternative` varchar(250) NOT NULL,
|
||||
`delete_date` varchar(14) NOT NULL,
|
||||
PRIMARY KEY (`content_id`,`bbs_id`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `g5_autosave`
|
||||
--
|
||||
|
||||
@@ -120,7 +120,7 @@ $sql = " insert into `{$table_prefix}config`
|
||||
cf_mobile_search_skin = 'basic',
|
||||
cf_mobile_connect_skin = 'basic',
|
||||
cf_mobile_member_skin = 'basic',
|
||||
cf_editor = 'ckeditor4',
|
||||
cf_editor = 'smarteditor2',
|
||||
cf_captcha_mp3 = 'basic',
|
||||
cf_register_level = '2',
|
||||
cf_register_point = '1000',
|
||||
@@ -245,7 +245,6 @@ fwrite($f, "\$g5['scrap_table'] = G5_TABLE_PREFIX.'scrap'; // 게시글 스크
|
||||
fwrite($f, "\$g5['visit_table'] = G5_TABLE_PREFIX.'visit'; // 방문자 테이블\n");
|
||||
fwrite($f, "\$g5['visit_sum_table'] = G5_TABLE_PREFIX.'visit_sum'; // 방문자 합계 테이블\n");
|
||||
fwrite($f, "\$g5['uniqid_table'] = G5_TABLE_PREFIX.'uniqid'; // 유니크한 값을 만드는 테이블\n");
|
||||
fwrite($f, "\$g5['syndi_log_table'] = G5_TABLE_PREFIX.'syndi_log'; // 네이버 신디케이션 컨텐츠 삭제 로그 테이블\n");
|
||||
fwrite($f, "\$g5['autosave_table'] = G5_TABLE_PREFIX.'autosave'; // 게시글 작성시 일정시간마다 글을 임시 저장하는 테이블\n");
|
||||
fwrite($f, "\$g5['cert_history_table'] = G5_TABLE_PREFIX.'cert_history'; // 인증내역 테이블\n");
|
||||
fwrite($f, "\$g5['qa_config_table'] = G5_TABLE_PREFIX.'qa_config'; // 1:1문의 설정테이블\n");
|
||||
|
||||
@@ -11,6 +11,8 @@ function autosave() {
|
||||
this.wr_content.value = CKEDITOR.instances.wr_content.getData();
|
||||
} else if (g5_editor.indexOf("cheditor5") != -1 && typeof(ed_wr_content)!="undefined") {
|
||||
this.wr_content.value = ed_wr_content.outputBodyHTML();
|
||||
} else if (g5_editor.indexOf("smarteditor2") != -1 && typeof(oEditors.getById['wr_content'])!="undefined" ) {
|
||||
this.wr_content.value = oEditors.getById['wr_content'].getIR();
|
||||
}
|
||||
// 변수에 저장해 놓은 값과 다를 경우에만 임시 저장함
|
||||
if (save_wr_subject != this.wr_subject.value || save_wr_content != this.wr_content.value) {
|
||||
@@ -79,6 +81,10 @@ $(function(){
|
||||
CKEDITOR.instances.wr_content.setData(content);
|
||||
} else if (g5_editor.indexOf("cheditor5") != -1 && typeof(ed_wr_content)!="undefined") {
|
||||
ed_wr_content.putContents(content);
|
||||
} else if (g5_editor.indexOf("smarteditor2") != -1 && typeof(oEditors.getById['wr_content'])!="undefined" ) {
|
||||
oEditors.getById["wr_content"].exec("SET_CONTENTS", [""]);
|
||||
//oEditors.getById["wr_content"].exec("SET_IR", [""]);
|
||||
oEditors.getById["wr_content"].exec("PASTE_HTML", [content]);
|
||||
} else {
|
||||
$("#fwrite #wr_content").val(content);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
function kakaolink_send(text, url)
|
||||
{
|
||||
// 카카오톡 링크 버튼을 생성합니다. 처음 한번만 호출하면 됩니다.
|
||||
Kakao.Link.sendTalkLink({
|
||||
webLink : {
|
||||
text: String(text),
|
||||
url: url // 앱 설정의 웹 플랫폼에 등록한 도메인의 URL이어야 합니다.
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -7,36 +7,6 @@ if (!defined('_GNUBOARD_')) exit;
|
||||
**
|
||||
*************************************************************************/
|
||||
|
||||
// multi-dimensional array에 사용자지정 함수적용
|
||||
function array_map_deep($fn, $array)
|
||||
{
|
||||
if(is_array($array)) {
|
||||
foreach($array as $key => $value) {
|
||||
if(is_array($value)) {
|
||||
$array[$key] = array_map_deep($fn, $value);
|
||||
} else {
|
||||
$array[$key] = call_user_func($fn, $value);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$array = call_user_func($fn, $array);
|
||||
}
|
||||
|
||||
return $array;
|
||||
}
|
||||
|
||||
// SQL Injection 대응 문자열 필터링
|
||||
function sql_escape_string($str)
|
||||
{
|
||||
$pattern = '/(and|or).*(union|select|insert|update|delete|from|where|limit|create|drop).*/i';
|
||||
$replace = '';
|
||||
|
||||
$str = preg_replace($pattern, $replace, $str);
|
||||
$str = call_user_func(G5_ESCAPE_FUNCTION, $str);
|
||||
|
||||
return $str;
|
||||
}
|
||||
|
||||
// 마이크로 타임을 얻어 계산 형식으로 만듦
|
||||
function get_microtime()
|
||||
{
|
||||
@@ -2670,7 +2640,7 @@ function get_search_string($stx)
|
||||
$stx_pattern[] = '#\.*/+#';
|
||||
$stx_pattern[] = '#\\\*#';
|
||||
$stx_pattern[] = '#\.{2,}#';
|
||||
$stx_pattern[] = '#[/\'\"%=*\#\(\)\|\+\-\&\!\$@~\{\}\[\]`;:\?\^\,]+#';
|
||||
$stx_pattern[] = '#[/\'\"%=*\#\(\)\|\+\&\!\$~\{\}\[\]`;:\?\^\,]+#';
|
||||
|
||||
$stx_replace = array();
|
||||
$stx_replace[] = '';
|
||||
|
||||
@@ -54,7 +54,7 @@ function latest($skin_dir='', $bo_table, $rows=10, $subject_len=40, $cache_time=
|
||||
|
||||
if($cache_fwrite) {
|
||||
$handle = fopen($cache_file, 'w');
|
||||
$cache_content = "<?php\nif (!defined('_GNUBOARD_')) exit;\n\$bo_subject=\"".$bo_subject."\";\n\$list=".var_export($list, true)."?>";
|
||||
$cache_content = "<?php\nif (!defined('_GNUBOARD_')) exit;\n\$bo_subject='".$bo_subject."';\n\$list=".var_export($list, true)."?>";
|
||||
fwrite($handle, $cache_content);
|
||||
fclose($handle);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,54 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit;
|
||||
|
||||
// http://kr1.php.net/manual/en/function.curl-setopt-array.php 참고
|
||||
if (!function_exists('curl_setopt_array')) {
|
||||
function curl_setopt_array(&$ch, $curl_options)
|
||||
{
|
||||
foreach ($curl_options as $option => $value) {
|
||||
if (!curl_setopt($ch, $option, $value)) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// 네이버 신디케이션에 ping url 을 curl 로 전달합니다.
|
||||
function naver_syndi_ping($bo_table, $wr_id)
|
||||
{
|
||||
global $config;
|
||||
|
||||
$token = trim($config['cf_syndi_token']);
|
||||
|
||||
// 토큰값이 없다면 네이버 신디케이션 사용안함
|
||||
if ($token == '') return 0;
|
||||
|
||||
// 신디케이션 수집 제외게시판
|
||||
if (preg_match('#^('.$config['cf_syndi_except'].')$#', $bo_table)) return -2;
|
||||
|
||||
// curl library 가 지원되어야 합니다.
|
||||
if (!function_exists('curl_init')) return -3;
|
||||
|
||||
$ping_auth_header = "Authorization: Bearer " . $token;
|
||||
$ping_url = urlencode( G5_SYNDI_URL . "/ping.php?bo_table={$bo_table}&wr_id={$wr_id}" );
|
||||
$ping_client_opt = array(
|
||||
CURLOPT_URL => "https://apis.naver.com/crawl/nsyndi/v2",
|
||||
CURLOPT_POST => true,
|
||||
CURLOPT_POSTFIELDS => "ping_url=" . $ping_url,
|
||||
CURLOPT_RETURNTRANSFER => true,
|
||||
CURLOPT_CONNECTTIMEOUT => 10,
|
||||
CURLOPT_TIMEOUT => 10,
|
||||
CURLOPT_HTTPHEADER => array("Host: apis.naver.com", "Pragma: no-cache", "Accept: */*", $ping_auth_header)
|
||||
);
|
||||
|
||||
//print_r2($ping_client_opt); exit;
|
||||
$ping = curl_init();
|
||||
curl_setopt_array($ping, $ping_client_opt);
|
||||
$response = curl_exec($ping);
|
||||
curl_close($ping);
|
||||
|
||||
return $response;
|
||||
}
|
||||
?>
|
||||
@@ -216,6 +216,7 @@
|
||||
#bo_vc a {color:#000;text-decoration:none}
|
||||
#bo_vc p {padding:0 0 5px;line-height:1.8em}
|
||||
#bo_vc p a {text-decoration:underline}
|
||||
#bo_vc p a.s_cmt {text-decoration:none}
|
||||
#bo_vc_empty {margin:0;padding:15px !important;text-align:center}
|
||||
#bo_vc #bo_vc_winfo {float:left}
|
||||
#bo_vc footer {zoom:1}
|
||||
|
||||
@@ -309,7 +309,12 @@ var char_max = parseInt(<?php echo $comment_max ?>); // 최대
|
||||
<?php if($board['bo_use_sns'] && ($config['cf_facebook_appid'] || $config['cf_twitter_key'])) { ?>
|
||||
// sns 등록
|
||||
$(function() {
|
||||
$("#bo_vc_send_sns").load( "<?php echo G5_SNS_URL; ?>/view_comment_write.sns.skin.php?bo_table=<?php echo $bo_table; ?>" );
|
||||
$("#bo_vc_send_sns").load(
|
||||
"<?php echo G5_SNS_URL; ?>/view_comment_write.sns.skin.php?bo_table=<?php echo $bo_table; ?>",
|
||||
function() {
|
||||
save_html = document.getElementById('bo_vc_w').innerHTML;
|
||||
}
|
||||
);
|
||||
});
|
||||
<?php } ?>
|
||||
</script>
|
||||
|
||||
@@ -203,6 +203,7 @@
|
||||
#bo_vc a {color:#000;text-decoration:none}
|
||||
#bo_vc p {padding:0 0 5px;line-height:1.8em}
|
||||
#bo_vc p a {text-decoration:underline}
|
||||
#bo_vc p a.s_cmt {text-decoration:none}
|
||||
#bo_vc_empty {margin:0;padding:15px !important;text-align:center}
|
||||
#bo_vc #bo_vc_winfo {float:left}
|
||||
#bo_vc footer {zoom:1}
|
||||
|
||||
@@ -309,7 +309,12 @@ var char_max = parseInt(<?php echo $comment_max ?>); // 최대
|
||||
<?php if($board['bo_use_sns'] && ($config['cf_facebook_appid'] || $config['cf_twitter_key'])) { ?>
|
||||
// sns 등록
|
||||
$(function() {
|
||||
$("#bo_vc_send_sns").load( "<?php echo G5_SNS_URL; ?>/view_comment_write.sns.skin.php?bo_table=<?php echo $bo_table; ?>" );
|
||||
$("#bo_vc_send_sns").load(
|
||||
"<?php echo G5_SNS_URL; ?>/view_comment_write.sns.skin.php?bo_table=<?php echo $bo_table; ?>",
|
||||
function() {
|
||||
save_html = document.getElementById('bo_vc_w').innerHTML;
|
||||
}
|
||||
);
|
||||
});
|
||||
<?php } ?>
|
||||
</script>
|
||||
|
||||
@@ -0,0 +1,74 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="ko" xml:lang="ko">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>네이버 :: Smart Editor 2 ™</title>
|
||||
<script type="text/javascript" src="./js/HuskyEZCreator.js" charset="utf-8"></script>
|
||||
</head>
|
||||
<body>
|
||||
<form action="sample.php" method="post">
|
||||
<textarea name="ir1" id="ir1" rows="10" cols="100" style="width:766px; height:412px; display:none;"></textarea>
|
||||
<!--textarea name="ir1" id="ir1" rows="10" cols="100" style="width:100%; height:412px; min-width:610px; display:none;"></textarea-->
|
||||
<p>
|
||||
<input type="button" onclick="pasteHTML();" value="본문에 내용 넣기" />
|
||||
<input type="button" onclick="showHTML();" value="본문 내용 가져오기" />
|
||||
<input type="button" onclick="submitContents(this);" value="서버로 내용 전송" />
|
||||
<input type="button" onclick="setDefaultFont();" value="기본 폰트 지정하기 (궁서_24)" />
|
||||
</p>
|
||||
</form>
|
||||
|
||||
<script type="text/javascript">
|
||||
var oEditors = [];
|
||||
|
||||
// 추가 글꼴 목록
|
||||
//var aAdditionalFontSet = [["MS UI Gothic", "MS UI Gothic"], ["Comic Sans MS", "Comic Sans MS"],["TEST","TEST"]];
|
||||
|
||||
nhn.husky.EZCreator.createInIFrame({
|
||||
oAppRef: oEditors,
|
||||
elPlaceHolder: "ir1",
|
||||
sSkinURI: "SmartEditor2Skin.html",
|
||||
htParams : {
|
||||
bUseToolbar : true, // 툴바 사용 여부 (true:사용/ false:사용하지 않음)
|
||||
bUseVerticalResizer : true, // 입력창 크기 조절바 사용 여부 (true:사용/ false:사용하지 않음)
|
||||
bUseModeChanger : true, // 모드 탭(Editor | HTML | TEXT) 사용 여부 (true:사용/ false:사용하지 않음)
|
||||
//aAdditionalFontList : aAdditionalFontSet, // 추가 글꼴 목록
|
||||
fOnBeforeUnload : function(){
|
||||
//alert("완료!");
|
||||
}
|
||||
}, //boolean
|
||||
fOnAppLoad : function(){
|
||||
//예제 코드
|
||||
//oEditors.getById["ir1"].exec("PASTE_HTML", ["로딩이 완료된 후에 본문에 삽입되는 text입니다."]);
|
||||
},
|
||||
fCreator: "createSEditor2"
|
||||
});
|
||||
|
||||
function pasteHTML() {
|
||||
var sHTML = "<span style='color:#FF0000;'>이미지도 같은 방식으로 삽입합니다.<\/span>";
|
||||
oEditors.getById["ir1"].exec("PASTE_HTML", [sHTML]);
|
||||
}
|
||||
|
||||
function showHTML() {
|
||||
var sHTML = oEditors.getById["ir1"].getIR();
|
||||
alert(sHTML);
|
||||
}
|
||||
|
||||
function submitContents(elClickedObj) {
|
||||
oEditors.getById["ir1"].exec("UPDATE_CONTENTS_FIELD", []); // 에디터의 내용이 textarea에 적용됩니다.
|
||||
|
||||
// 에디터의 내용에 대한 값 검증은 이곳에서 document.getElementById("ir1").value를 이용해서 처리하면 됩니다.
|
||||
|
||||
try {
|
||||
elClickedObj.form.submit();
|
||||
} catch(e) {}
|
||||
}
|
||||
|
||||
function setDefaultFont() {
|
||||
var sDefaultFont = '궁서';
|
||||
var nFontSize = 24;
|
||||
oEditors.getById["ir1"].setDefaultFont(sDefaultFont, nFontSize);
|
||||
}
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,29 @@
|
||||
(function($){
|
||||
$(document).ready(function() {
|
||||
$(".smarteditor2").each( function(index){
|
||||
var get_id = $(this).attr("id");
|
||||
|
||||
if( !get_id || $(this).prop("nodeName") != 'TEXTAREA' ) return true;
|
||||
|
||||
nhn.husky.EZCreator.createInIFrame({
|
||||
oAppRef: oEditors,
|
||||
elPlaceHolder: get_id,
|
||||
sSkinURI: g5_editor_url+"/SmartEditor2Skin.html",
|
||||
htParams : {
|
||||
bUseToolbar : true, // 툴바 사용 여부 (true:사용/ false:사용하지 않음)
|
||||
bUseVerticalResizer : true, // 입력창 크기 조절바 사용 여부 (true:사용/ false:사용하지 않음)
|
||||
bUseModeChanger : true, // 모드 탭(Editor | HTML | TEXT) 사용 여부 (true:사용/ false:사용하지 않음)
|
||||
//aAdditionalFontList : aAdditionalFontSet, // 추가 글꼴 목록
|
||||
fOnBeforeUnload : function(){
|
||||
//alert("완료!");
|
||||
}
|
||||
}, //boolean
|
||||
fOnAppLoad : function(){
|
||||
//예제 코드
|
||||
//oEditors.getById["ir1"].exec("PASTE_HTML", ["로딩이 완료된 후에 본문에 삽입되는 text입니다."]);
|
||||
},
|
||||
fCreator: "createSEditor2"
|
||||
});
|
||||
});
|
||||
});
|
||||
})(jQuery);
|
||||
@@ -0,0 +1,336 @@
|
||||
@charset "UTF-8";
|
||||
/* NHN Web Standardization Team (http://html.nhndesign.com/) HHJ 090226 */
|
||||
/* COMMON */
|
||||
body, #smart_editor2, #smart_editor2 p, #smart_editor2 h1, #smart_editor2 h2, #smart_editor2 h3, #smart_editor2 h4, #smart_editor2 h5, #smart_editor2 h6, #smart_editor2 ul, #smart_editor2 ol, #smart_editor2 li, #smart_editor2 dl, #smart_editor2 dt, #smart_editor2 dd, #smart_editor2 table, #smart_editor2 th, #smart_editor2 td, #smart_editor2 form, #smart_editor2 fieldset, #smart_editor2 legend, #smart_editor2 input, #smart_editor2 textarea, #smart_editor2 button, #smart_editor2 select { margin: 0; padding: 0; }
|
||||
|
||||
#smart_editor2, #smart_editor2 h1, #smart_editor2 h2, #smart_editor2 h3, #smart_editor2 h4, #smart_editor2 h5, #smart_editor2 h6, #smart_editor2 input, #smart_editor2 textarea, #smart_editor2 select, #smart_editor2 table, #smart_editor2 button { font-family: '돋움',Dotum,Helvetica,sans-serif; font-size: 12px; color: #666; }
|
||||
|
||||
#smart_editor2 span, #smart_editor2 em { font-size: 12px; }
|
||||
|
||||
#smart_editor2 em, #smart_editor2 address { font-style: normal; }
|
||||
|
||||
#smart_editor2 img, #smart_editor2 fieldset { border: 0; }
|
||||
|
||||
#smart_editor2 hr { display: none; }
|
||||
|
||||
#smart_editor2 ol, #smart_editor2 ul { list-style: none; }
|
||||
|
||||
#smart_editor2 button { border: 0; background: none; font-size: 11px; vertical-align: top; cursor: pointer; }
|
||||
|
||||
#smart_editor2 button span, #smart_editor2 button em { visibility: hidden; overflow: hidden; position: absolute; top: 0; font-size: 0; line-height: 0; }
|
||||
|
||||
#smart_editor2 legend, #smart_editor2 .blind { visibility: hidden; overflow: hidden; position: absolute; width: 0; height: 0; font-size: 0; line-height: 0; }
|
||||
|
||||
#smart_editor2 .input_ty1 { height: 14px; margin: 0; padding: 4px 2px 0 4px; border: 1px solid #c7c7c7; font-size: 11px; color: #666; }
|
||||
|
||||
#smart_editor2 a:link, #smart_editor2 a:visited, #smart_editor2 a:active, #smart_editor2 a:focus { color: #666; text-decoration: none; }
|
||||
|
||||
#smart_editor2 a:hover { color: #666; text-decoration: underline; }
|
||||
|
||||
/* LAYOUT */
|
||||
#smart_editor2 .se2_header { margin: 10px 0 29px 0; }
|
||||
|
||||
#smart_editor2 .se2_bi { float: left; width: 93px; height: 20px; margin: 0; padding: 0; background: url("../img/ko_KR/btn_set.png?130306") -343px -358px no-repeat; font-size: 0; line-height: 0; text-indent: -10000px; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_allhelp { display: inline-block; width: 18px; height: 18px; padding: 0; background: url("../img/ko_KR/btn_set.png?130306") -437px -358px no-repeat; font-size: 0; line-height: 0; text-indent: -10000px; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 #smart_editor2_content { border: 1px solid #b5b5b5; }
|
||||
|
||||
#smart_editor2 .se2_tool { overflow: visible; position: relative; z-index: 25; }
|
||||
|
||||
/* EDITINGAREA */
|
||||
#smart_editor2 .se2_input_area { position: relative; z-index: 22; height: 400px; margin: 0; padding: 0; *zoom: 1; }
|
||||
|
||||
#smart_editor2 .se2_input_wysiwyg, #smart_editor2 .se2_input_syntax { display: block; overflow: auto; width: 100%; height: 100%; margin: 0; *margin: -1px 0 0 0; border: 0; }
|
||||
|
||||
/* EDITINGMODE */
|
||||
#smart_editor2 .se2_conversion_mode { position: relative; height: 15px; padding-top: 1px; border-top: 1px solid #b5b5b5; background: url("../img/icon_set.gif") 0 -896px repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_inputarea_controller { display: block; clear: both; position: relative; width: 100%; height: 15px; text-align: center; cursor: n-resize; }
|
||||
|
||||
#smart_editor2 .se2_inputarea_controller span, #smart_editor2 .controller_on span { background: url("../img/ico_extend.png") no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_inputarea_controller span { position: static; display: inline-block; visibility: visible; overflow: hidden; height: 15px; padding-left: 11px; background-position: 0 2px; color: #888; font-size: 11px; letter-spacing: -1px; line-height: 16px; white-space: nowrap; }
|
||||
|
||||
* + html #smart_editor2 .se2_inputarea_controller span { line-height: 14px; }
|
||||
|
||||
#smart_editor2 .controller_on span { background-position: 0 -21px; color: #249c04; }
|
||||
|
||||
#smart_editor2 .ly_controller { display: block; position: absolute; bottom: 2px; left: 50%; width: 287px; margin-left: -148px; padding: 8px 0 7px 9px; border: 1px solid #827f7c; background: #fffdef; }
|
||||
|
||||
#smart_editor2 .ly_controller p { color: #666; font-size: 11px; letter-spacing: -1px; line-height: 11px; }
|
||||
|
||||
#smart_editor2 .ly_controller .bt_clse, #smart_editor2 .ly_controller .ic_arr { position: absolute; background: url("../img/ico_extend.png") no-repeat; }
|
||||
|
||||
#smart_editor2 .ly_controller .bt_clse { top: 5px; right: 4px; width: 14px; height: 15px; background-position: 1px -43px; }
|
||||
|
||||
#smart_editor2 .ly_controller .ic_arr { top: 25px; left: 50%; width: 10px; height: 6px; margin-left: -5px; background-position: 0 -65px; }
|
||||
|
||||
#smart_editor2 .se2_converter { float: left; position: absolute; top: -1px; right: 3px; z-index: 20; }
|
||||
|
||||
#smart_editor2 .se2_converter li { float: left; }
|
||||
|
||||
#smart_editor2 .se2_converter .se2_to_editor { width: 59px; height: 15px; background: url("../img/ko_KR/btn_set.png?130306") 0 -85px no-repeat; vertical-align: top; }
|
||||
|
||||
#smart_editor2 .se2_converter .se2_to_html { width: 59px; height: 15px; background: url("../img/ko_KR/btn_set.png?130306") -59px -70px no-repeat; vertical-align: top; }
|
||||
|
||||
#smart_editor2 .se2_converter .se2_to_text { width: 60px; height: 15px; background: url("../img/ko_KR/btn_set.png?130306") -417px -466px no-repeat; vertical-align: top; }
|
||||
|
||||
#smart_editor2 .se2_converter .active .se2_to_editor { width: 59px; height: 15px; background: url("../img/ko_KR/btn_set.png?130306") 0 -70px no-repeat; vertical-align: top; }
|
||||
|
||||
#smart_editor2 .se2_converter .active .se2_to_html { width: 59px; height: 15px; background: url("../img/ko_KR/btn_set.png?130306") -59px -85px no-repeat; vertical-align: top; }
|
||||
|
||||
#smart_editor2 .se2_converter .active .se2_to_text { width: 60px; height: 15px; background: url("../img/ko_KR/btn_set.png?130306") -417px -481px no-repeat; vertical-align: top; }
|
||||
|
||||
/* EDITINGAREA_HTMLSRC */
|
||||
#smart_editor2 .off .ico_btn, #smart_editor2 .off .se2_more, #smart_editor2 .off .se2_more2, #smart_editor2 .off .se2_font_family, #smart_editor2 .off .se2_font_size, #smart_editor2 .off .se2_bold, #smart_editor2 .off .se2_underline, #smart_editor2 .off .se2_italic, #smart_editor2 .off .se2_tdel, #smart_editor2 .off .se2_fcolor, #smart_editor2 .off .se2_fcolor_more, #smart_editor2 .off .se2_bgcolor, #smart_editor2 .off .se2_bgcolor_more, #smart_editor2 .off .se2_left, #smart_editor2 .off .se2_center, #smart_editor2 .off .se2_right, #smart_editor2 .off .se2_justify, #smart_editor2 .off .se2_ol, #smart_editor2 .off .se2_ul, #smart_editor2 .off .se2_indent, #smart_editor2 .off .se2_outdent, #smart_editor2 .off .se2_lineheight, #smart_editor2 .off .se2_del_style, #smart_editor2 .off .se2_blockquote, #smart_editor2 .off .se2_summary, #smart_editor2 .off .se2_footnote, #smart_editor2 .off .se2_url, #smart_editor2 .off .se2_emoticon, #smart_editor2 .off .se2_character, #smart_editor2 .off .se2_table, #smart_editor2 .off .se2_find, #smart_editor2 .off .se2_spelling, #smart_editor2 .off .se2_sup, #smart_editor2 .off .se2_sub, #smart_editor2 .off .se2_text_tool_more, #smart_editor2 .off .se2_new, #smart_editor2 .off .selected_color, #smart_editor2 .off .se2_lineSticker { -ms-filter: alpha(opacity=50); opacity: .5; cursor: default; filter: alpha(opacity=50); }
|
||||
|
||||
/* LAYER */
|
||||
#smart_editor2 .se2_text_tool .se2_layer { display: none; float: left; position: absolute; top: 20px; left: 0; z-index: 50; margin: 0; padding: 0; border: 1px solid #bcbbbb; background: #fafafa; }
|
||||
|
||||
#smart_editor2 .se2_text_tool li.active { z-index: 50; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_layer { display: block; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active li .se2_layer { display: none; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .active .se2_layer { display: block; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_layer .se2_in_layer { float: left; margin: 0; padding: 0; border: 1px solid #fff; background: #fafafa; }
|
||||
|
||||
/* TEXT_TOOLBAR */
|
||||
#smart_editor2 .se2_text_tool { position: relative; clear: both; z-index: 30; padding: 4px 0 4px 3px; background: #f4f4f4 url("../img/bg_text_tool.gif") 0 0 repeat-x; border-bottom: 1px solid #b5b5b5; *zoom: 1; }
|
||||
|
||||
#smart_editor2 .se2_text_tool:after { content: ""; display: block; clear: both; }
|
||||
|
||||
#smart_editor2 .se2_text_tool ul { float: left; display: inline; margin-right: 3px; padding-left: 1px; white-space: nowrap; }
|
||||
|
||||
#smart_editor2 .se2_text_tool li { _display: inline; float: left; position: relative; z-index: 30; }
|
||||
|
||||
#smart_editor2 .se2_text_tool button, #smart_editor2 .se2_multy .se2_icon { width: 21px; height: 21px; background: url("../img/ko_KR/text_tool_set.png?140317") no-repeat; vertical-align: top; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_font_type { position: relative; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_font_type li { margin-left: 3px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_font_type button { text-align: left; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_font_type button.se2_font_family span, #smart_editor2 .se2_text_tool .se2_font_type button.se2_font_size span { display: inline-block; visibility: visible; position: static; width: 52px; height: 20px; padding: 0 0 0 6px; font-size: 12px; line-height: 20px; *line-height: 22px; color: #333; *zoom: 1; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_multy { position: absolute; top: 0; right: 0; padding-left: 0; margin-right: 0; white-space: nowrap; border-left: 1px solid #e0dedf; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_multy .se2_mn { float: left; white-space: nowrap; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_multy button { background-image: none; width: 47px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_multy .se2_icon { display: inline-block; visibility: visible; overflow: visible; position: static; width: 16px; height: 29px; margin: -1px 2px 0 -1px; background-position: 0 -132px; line-height: 30px; vertical-align: top; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_multy button, #smart_editor2 .se2_text_tool .se2_multy button span { height: 29px; line-height: 29px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_map .se2_icon { background-position: -29px -132px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool button span.se2_mntxt { display: inline-block; visibility: visible; overflow: visible; _overflow-y: hidden; position: relative; *margin-right: -1px; width: auto; height: 29px; font-weight: normal; font-size: 11px; line-height: 30px; *line-height: 29px; _line-height: 30px; color: #444; letter-spacing: -1px; vertical-align: top; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_multy .se2_photo { margin-right: 1px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_multy .hover .ico_btn { background: #e8e8e8; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_multy .se2_mn.hover { background: #e0dedf; }
|
||||
|
||||
/* TEXT_TOOLBAR : ROUNDING */
|
||||
#smart_editor2 ul li.first_child button span.tool_bg, #smart_editor2 ul li.last_child button span.tool_bg, #smart_editor2 ul li.single_child button span.tool_bg { visibility: visible; height: 21px; }
|
||||
|
||||
#smart_editor2 ul li.first_child button span.tool_bg { left: -1px; width: 3px; background: url("../img/bg_button_left.gif?20121228") no-repeat; }
|
||||
|
||||
#smart_editor2 ul li.last_child button span.tool_bg { right: 0px; _right: -1px; width: 2px; background: url("../img/bg_button_right.gif") no-repeat; }
|
||||
|
||||
#smart_editor2 ul li.single_child { padding-right: 1px; }
|
||||
|
||||
#smart_editor2 ul li.single_child button span.tool_bg { left: 0; background: url("../img/bg_button.gif?20121228") no-repeat; width: 22px; }
|
||||
|
||||
#smart_editor2 div.se2_text_tool ul li.hover button span.tool_bg { background-position: 0 -21px; }
|
||||
|
||||
#smart_editor2 div.se2_text_tool ul li.active button span.tool_bg, #smart_editor2 div.se2_text_tool ul li.active li.active button span.tool_bg { background-position: 0 -42px; }
|
||||
|
||||
#smart_editor2 div.se2_text_tool ul li.active li button span.tool_bg { background-position: 0 0; }
|
||||
|
||||
/* TEXT_TOOLBAR : SUB_MENU */
|
||||
#smart_editor2 .se2_sub_text_tool { display: none; position: absolute; top: 20px; left: 0; z-index: 40; width: auto; height: 29px; padding: 0 4px 0 0; border: 1px solid #b5b5b5; border-top: 1px solid #9a9a9a; background: #f4f4f4; }
|
||||
|
||||
#smart_editor2 .active .se2_sub_text_tool { display: block; }
|
||||
|
||||
#smart_editor2 .se2_sub_text_tool ul { float: left; height: 25px; margin: 0; padding: 4px 0 0 4px; }
|
||||
|
||||
/* TEXT_TOOLBAR : SUB_MENU_SIZE */
|
||||
#smart_editor2 .se2_sub_step1 { width: 88px; }
|
||||
|
||||
#smart_editor2 .se2_sub_step2 { width: 199px; }
|
||||
|
||||
#smart_editor2 .se2_sub_step2_1 { width: 178px; }
|
||||
|
||||
/* TEXT_TOOLBAR : BUTTON */
|
||||
#smart_editor2 .se2_text_tool .se2_font_family { width: 70px; height: 21px; background-position: 0 -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_font_family { background-position: 0 -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_font_family { background-position: 0 -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_font_size { width: 45px; height: 21px; background-position: -70px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_font_size { background-position: -70px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_font_size { background-position: -70px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_bold { background-position: -115px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_bold { background-position: -115px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_bold { background-position: -115px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_underline { background-position: -136px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_underline { background-position: -136px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_underline { background-position: -136px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_italic { background-position: -157px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_italic { background-position: -157px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_italic { background-position: -157px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_tdel { background-position: -178px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_tdel { background-position: -178px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_tdel { background-position: -178px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_fcolor { position: relative; background-position: -199px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_fcolor { background-position: -199px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_fcolor { background-position: -199px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_fcolor_more { background-position: -220px -10px; width: 10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_fcolor_more { background-position: -220px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_fcolor_more { background-position: -220px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .selected_color { position: absolute; top: 14px; left: 5px; width: 11px; height: 3px; font-size: 0; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_ol, #smart_editor2 .se2_text_tool .active .se2_sub_text_tool .se2_ol { background-position: -345px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_ul, #smart_editor2 .se2_text_tool .active .se2_sub_text_tool .se2_ul { background-position: -366px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_ol, #smart_editor2 .se2_text_tool .active .se2_sub_text_tool .hover .se2_ol { background-position: -345px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_ul, #smart_editor2 .se2_text_tool .active .se2_sub_text_tool .hover .se2_ul { background-position: -366px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_ol, #smart_editor2 .se2_text_tool .active .active .se2_ol { background-position: -345px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_ul, #smart_editor2 .se2_text_tool .active .active .se2_ul { background-position: -366px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_indent, #smart_editor2 .se2_text_tool .active .se2_sub_text_tool .se2_indent { background-position: -408px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_outdent, #smart_editor2 .se2_text_tool .active .se2_sub_text_tool .se2_outdent { background-position: -387px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_indent, #smart_editor2 .se2_text_tool .active .se2_sub_text_tool .hover .se2_indent { background-position: -408px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_outdent, #smart_editor2 .se2_text_tool .active .se2_sub_text_tool .hover .se2_outdent { background-position: -387px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_indent, #smart_editor2 .se2_text_tool .active .active .se2_indent { background-position: -408px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_outdent, #smart_editor2 .se2_text_tool .active .active .se2_outdent { background-position: -387px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_lineheight { background-position: -429px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_lineheight { background-position: -429px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_lineheight { background-position: -429px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_url { background-position: -513px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_url { background-position: -513px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_url { background-position: -513px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_bgcolor { position: relative; background-position: -230px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_bgcolor { background-position: -230px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_bgcolor { background-position: -230px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_bgcolor_more { background-position: -251px -10px; width: 10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_bgcolor_more { background-position: -251px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_bgcolor_more { background-position: -251px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_left { background-position: -261px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_left { background-position: -261px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_left { background-position: -261px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_center { background-position: -282px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_center { background-position: -282px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_center { background-position: -282px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_right { background-position: -303px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_right { background-position: -303px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_right { background-position: -303px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_justify { background-position: -324px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_justify { background-position: -324px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_justify { background-position: -324px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_blockquote { background-position: -471px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_blockquote { background-position: -471px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_blockquote { background-position: -471px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_character { background-position: -555px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_character { background-position: -555px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_character { background-position: -555px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_table { background-position: -576px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_table { background-position: -576px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_table { background-position: -576px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_find { background-position: -597px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_find { background-position: -597px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_find { background-position: -597px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_sup { background-position: -660px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_sup { background-position: -660px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_sup { background-position: -660px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_sub { background-position: -681px -10px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_sub { background-position: -681px -72px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_sub { background-position: -681px -103px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_text_tool_more { background-position: 0 -41px; width: 13px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .se2_text_tool_more span.tool_bg { background: none; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .hover .se2_text_tool_more { background-position: -13px -41px; }
|
||||
|
||||
#smart_editor2 .se2_text_tool .active .se2_text_tool_more { background-position: -26px -41px; }
|
||||
@@ -0,0 +1,34 @@
|
||||
@charset "UTF-8";
|
||||
/* NHN Web Standardization Team (http://html.nhndesign.com/) HHJ 090226 */
|
||||
/* COMMON */
|
||||
body, .se2_inputarea { margin: 0; padding: 0; font-family: '돋움',Dotum,Helvetica,Sans-serif; font-size: 12px; line-height: 1.5; }
|
||||
|
||||
/* body,.se2_inputarea,.se2_inputarea th,.se2_inputarea td{margin:0;padding:0;font-family:'돋움',Dotum,Helvetica,Sans-serif;font-size:12px;line-height:1.5;color:#666} */
|
||||
.se2_inputarea p, .se2_inputarea br { margin: 0; padding: 0; }
|
||||
|
||||
.se2_inputarea { margin: 15px; word-wrap: break-word; *word-wrap: normal; *word-break: break-all; }
|
||||
|
||||
.se2_inputarea_890 { width: 741px; margin: 20px 0 10px 64px; }
|
||||
|
||||
.se2_inputarea_698 { width: 548px; margin: 20px 0 10px 64px; }
|
||||
|
||||
/* TEXT_TOOLBAR : QUOTE */
|
||||
.se2_quote1 { margin: 0 0 30px 20px; padding: 0 8px; border-left: 2px solid #ccc; color: #888; }
|
||||
|
||||
.se2_quote2 { margin: 0 0 30px 13px; padding: 0 8px 0 16px; background: url("../img/bg_quote2.gif") 0 3px no-repeat; color: #888; }
|
||||
|
||||
.se2_quote3 { margin: 0 0 30px; padding: 12px 10px 11px; border: 1px dashed #ccc; color: #888; }
|
||||
|
||||
.se2_quote4 { margin: 0 0 30px; padding: 12px 10px 11px; border: 1px dashed #66b246; color: #888; }
|
||||
|
||||
.se2_quote5 { margin: 0 0 30px; padding: 12px 10px 11px; border: 1px dashed #ccc; background: #fafafa; color: #888; }
|
||||
|
||||
.se2_quote6 { margin: 0 0 30px; padding: 12px 10px 11px; border: 1px solid #e5e5e5; color: #888; }
|
||||
|
||||
.se2_quote7 { margin: 0 0 30px; padding: 12px 10px 11px; border: 1px solid #66b246; color: #888; }
|
||||
|
||||
.se2_quote8 { margin: 0 0 30px; padding: 12px 10px 11px; border: 1px solid #e5e5e5; background: #fafafa; color: #888; }
|
||||
|
||||
.se2_quote9 { margin: 0 0 30px; padding: 12px 10px 11px; border: 2px solid #e5e5e5; color: #888; }
|
||||
|
||||
.se2_quote10 { margin: 0 0 30px; padding: 12px 10px 11px; border: 2px solid #e5e5e5; background: #fafafa; color: #888; }
|
||||
@@ -0,0 +1,894 @@
|
||||
@charset "UTF-8";
|
||||
/* NHN Web Standardization Team (http://html.nhndesign.com/) HHJ 090226 */
|
||||
/* TEXT_TOOLBAR : FONTNAME */
|
||||
#smart_editor2 .se2_tool .se2_l_font_fam { width: 202px; margin: 0; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_tool .se2_l_font_fam li { display: block; width: 202px; height: 21px; margin: 0; padding: 0; color: #333; cursor: pointer; }
|
||||
|
||||
#smart_editor2 .se2_l_font_fam .hover, #smart_editor2 .se2_l_font_fam .active { background: #ebebeb; }
|
||||
|
||||
#smart_editor2 .se2_l_font_fam button { width: 200px; height: 21px; margin: 0; padding: 2px 0 2px 0px; background: none; text-align: left; }
|
||||
|
||||
#smart_editor2 .se2_l_font_fam button span { display: block; visibility: visible; overflow: visible; position: relative; top: auto; left: auto; width: auto; height: auto; margin: 0 0 0 4px; padding: 0; font-size: 12px; line-height: normal; color: #333; }
|
||||
|
||||
#smart_editor2 .se2_l_font_fam button span span { display: inline; visibility: visible; overflow: visible; width: auto; height: auto; margin: 0 0 0 4px; font-family: Verdana; font-size: 12px; line-height: 14px; color: #888; }
|
||||
|
||||
#smart_editor2 .se2_l_font_fam button span em { visibility: visible; overflow: auto; position: static; width: auto; height: auto; margin-right: -4px; font-size: 12px; color: #888; }
|
||||
|
||||
#smart_editor2 .se2_l_font_fam .se2_division { width: 162px; height: 2px !important; margin: 1px 0 1px 0px; border: 0; background: url("../img/bg_line1.gif") 0 0 repeat-x; font-size: 0; cursor: default; }
|
||||
|
||||
/* TEXT_TOOLBAR : FONTSIZE */
|
||||
#smart_editor2 .se2_tool .se2_l_font_size { width: 302px; margin: 0; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_tool .se2_l_font_size li { width: 302px; margin: 0; padding: 0; color: #333; cursor: pointer; }
|
||||
|
||||
#smart_editor2 .se2_l_font_size .hover, #smart_editor2 .se2_l_font_size .active { background: #ebebeb; }
|
||||
|
||||
#smart_editor2 .se2_l_font_size button { width: 300px; margin: 0; padding: 2px 0 1px 0px; *padding: 4px 0 1px 0px; background: none; text-align: left; }
|
||||
|
||||
#smart_editor2 .se2_l_font_size button span { display: block; visibility: visible; overflow: visible; position: relative; top: auto; left: auto; width: auto; height: auto; margin: 0 0 0 4px; padding: 0; line-height: normal; color: #373737; letter-spacing: 0px; }
|
||||
|
||||
#smart_editor2 .se2_l_font_size button span span { display: inline; margin: 0 0 0 5px; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_l_font_size span em { visibility: visible; overflow: auto; position: static; width: auto; height: auto; color: #888; }
|
||||
|
||||
/* TEXT_TOOLBAR : FONTCOLOR */
|
||||
#smart_editor2 .se2_palette { float: left; position: relative; width: 225px; margin: 0; padding: 11px 0 10px 0; }
|
||||
|
||||
#smart_editor2 .se2_palette .se2_pick_color { _display: inline; float: left; clear: both; width: 205px; margin: 0 0 0 11px; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_palette .se2_pick_color li { float: left; width: 12px; height: 12px; margin: 0; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_palette .se2_pick_color li button { width: 11px; height: 11px; border: 0; }
|
||||
|
||||
#smart_editor2 .se2_palette .se2_pick_color li button span { display: block; visibility: visible; overflow: visible; position: absolute; top: 1px; left: 1px; width: 11px; height: 11px; }
|
||||
|
||||
#smart_editor2 .se2_palette .se2_pick_color li button span span { visibility: hidden; overflow: hidden; position: absolute; top: 0; left: 0; width: 0; height: 0; }
|
||||
|
||||
#smart_editor2 .se2_palette .se2_pick_color .hover button, #smart_editor2 .se2_palette .se2_pick_color .active button { width: 11px; height: 11px; border: 1px solid #666; }
|
||||
|
||||
#smart_editor2 .se2_palette .se2_pick_color .hover span, #smart_editor2 .se2_palette .se2_pick_color .active span { width: 7px; height: 7px; border: 1px solid #fff; }
|
||||
|
||||
#smart_editor2 .se2_palette .se2_view_more { _display: inline; float: left; width: 46px; height: 23px; margin: 1px 0 0 1px; background: url("../img/ko_KR/btn_set.png?130306") 0 -47px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_palette .se2_view_more2 { _display: inline; float: left; width: 46px; height: 23px; margin: 1px 0 0 1px; background: url("../img/ko_KR/btn_set.png?130306") 0 -24px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_palette h4 { _display: inline; float: left; width: 203px; margin: 9px 0 0 11px; padding: 10px 0 4px 0; background: url("../img/bg_line1.gif") repeat-x; font-weight: normal; font-size: 12px; line-height: 14px; color: #333; letter-spacing: -1px; }
|
||||
|
||||
#smart_editor2 .se2_palette2 { float: left; _float: none; width: 214px; margin: 9px 0 0 0; padding: 11px 0 0 11px; background: url("../img/bg_line1.gif") repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_palette2 .se2_color_set { float: left; }
|
||||
|
||||
#smart_editor2 .se2_palette2 .se2_selected_color { _display: inline; float: left; width: 83px; height: 18px; margin: 0; border: 1px solid #c7c7c7; background: #fff; }
|
||||
|
||||
#smart_editor2 .se2_palette2 .se2_selected_color span { _display: inline; float: left; width: 79px; height: 14px; margin: 2px; }
|
||||
|
||||
#smart_editor2 .se2_palette2 .input_ty1 { _display: inline; float: left; width: 67px; height: 16px; margin: 0 3px 0 3px; padding: 2px 2px 0 4px; font-family: tahoma; font-size: 11px; }
|
||||
|
||||
#smart_editor2 .se2_palette2 button.se2_btn_insert { float: left; width: 35px; height: 21px; margin-left: 2px; padding: 0; background: url("../img/ko_KR/btn_set.png?130306") -80px 0 no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_gradation1 { float: left; _float: none; width: 201px; height: 128px; margin: 4px 0 0 0; border: 1px solid #c7c7c7; cursor: crosshair; }
|
||||
|
||||
#smart_editor2 .se2_gradation2 { float: left; _float: none; width: 201px; height: 10px; margin: 4px 0 1px 0; border: 1px solid #c7c7c7; cursor: crosshair; }
|
||||
|
||||
/* TEXT_TOOLBAR : BGCOLOR */
|
||||
#smart_editor2 .se2_palette_bgcolor { width: 225px; margin: 11px 0 0; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_palette_bgcolor .se2_background { width: 205px; margin: 0 11px 0 11px; }
|
||||
|
||||
#smart_editor2 .se2_palette_bgcolor .se2_background li { width: 68px; height: 20px; }
|
||||
|
||||
#smart_editor2 .se2_palette_bgcolor .se2_background button { width: 67px; height: 19px; border: 0; }
|
||||
|
||||
#smart_editor2 .se2_palette_bgcolor .se2_background span { left: 0; display: block; visibility: visible; overflow: visible; width: 65px; height: 17px; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_palette_bgcolor .se2_background span span { display: block; visibility: visible; overflow: visible; width: 64px; height: 16px; padding: 3px 0 0 3px; font-size: 11px; line-height: 14px; text-align: left; }
|
||||
|
||||
#smart_editor2 .se2_palette_bgcolor .se2_background .hover span { width: 65px; height: 17px; border: 1px solid #666; }
|
||||
|
||||
#smart_editor2 .se2_palette_bgcolor .se2_background .hover span span { width: 62px; height: 14px; padding: 1px 0 0 1px; border: 1px solid #fff; }
|
||||
|
||||
/* TEXT_TOOLBAR : LINEHEIGHT */
|
||||
#smart_editor2 .se2_l_line_height { width: 107px; margin: 0; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_l_line_height li { width: 107px; margin: 0; padding: 0; border-top: 0; border-bottom: 0; color: #333; cursor: pointer; }
|
||||
|
||||
#smart_editor2 .se2_l_line_height .hover { background: #ebebeb; }
|
||||
|
||||
#smart_editor2 .se2_l_line_height button { width: 105px; height: 19px; margin: 0; padding: 3px 0 2px 0px; background: none; text-align: left; }
|
||||
|
||||
#smart_editor2 .se2_l_line_height button span { visibility: visible; overflow: visible; position: relative; width: auto; height: auto; margin: 0; padding: 0 0 0 15px; font-size: 12px; line-height: normal; color: #373737; }
|
||||
|
||||
#smart_editor2 .se2_l_line_height li button.active span { background: url("../img/icon_set.gif") 5px -30px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_l_line_height_user { clear: both; width: 83px; margin: 5px 0 0 12px; padding: 10px 0 0 0; _padding: 11px 0 0 0; background: url("../img/bg_line1.gif") repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_l_line_height_user h3 { margin: 0 0 4px 0; _margin: 0 0 2px -1px; padding: 0; line-height: 14px; color: #000; letter-spacing: -1px; }
|
||||
|
||||
#smart_editor2 .se2_l_line_height_user .bx_input { display: block; position: relative; width: 83px; }
|
||||
|
||||
#smart_editor2 .se2_l_line_height_user .btn_up { position: absolute; top: 2px; *top: 3px; left: 68px; width: 13px; height: 8px; background: url("../img/ko_KR/btn_set.png?130306") -86px -54px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_l_line_height_user .btn_down { position: absolute; top: 10px; *top: 11px; left: 68px; width: 13px; height: 8px; background: url("../img/ko_KR/btn_set.png?130306") -86px -62px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_l_line_height_user .btn_area { margin: 5px 0 10px 0; }
|
||||
|
||||
#smart_editor2 .se2_tool .btn_area .se2_btn_apply3 { width: 41px; height: 24px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_tool .btn_area .se2_btn_cancel3 { width: 39px; height: 24px; margin-left: 3px; background: url("../img/ko_KR/btn_set.png?130306") -41px 0 no-repeat; }
|
||||
|
||||
/* TEXT_TOOLBAR : QUOTE */
|
||||
#smart_editor2 .se2_quote { width: 425px; height: 56px; }
|
||||
|
||||
#smart_editor2 .se2_quote ul { _display: inline; float: left; margin: 11px 0 0 9px; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_quote li { _display: inline; float: left; margin: 0 0 0 2px; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_quote button { width: 34px; height: 34px; margin: 0; padding: 0; background: url("../img/ko_KR/btn_set.png?130306") no-repeat; cursor: pointer; }
|
||||
|
||||
#smart_editor2 .se2_quote button span { left: 0; display: block; visibility: visible; overflow: visible; width: 32px; height: 32px; margin: 0; padding: 0; border: 1px solid #c7c7c7; }
|
||||
|
||||
#smart_editor2 .se2_quote button span span { visibility: hidden; overflow: hidden; position: absolute; top: 0; left: 0; width: 0; height: 0; margin: 0; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_quote .se2_quote1 { background-position: 1px -375px; }
|
||||
|
||||
#smart_editor2 .se2_quote .se2_quote2 { background-position: -32px -375px; }
|
||||
|
||||
#smart_editor2 .se2_quote .se2_quote3 { background-position: -65px -375px; }
|
||||
|
||||
#smart_editor2 .se2_quote .se2_quote4 { background-position: -98px -375px; }
|
||||
|
||||
#smart_editor2 .se2_quote .se2_quote5 { background-position: -131px -375px; }
|
||||
|
||||
#smart_editor2 .se2_quote .se2_quote6 { background-position: -164px -375px; }
|
||||
|
||||
#smart_editor2 .se2_quote .se2_quote7 { background-position: -197px -375px; }
|
||||
|
||||
#smart_editor2 .se2_quote .se2_quote8 { background-position: -230px -375px; }
|
||||
|
||||
#smart_editor2 .se2_quote .se2_quote9 { background-position: -263px -375px; }
|
||||
|
||||
#smart_editor2 .se2_quote .se2_quote10 { background-position: -296px -375px; }
|
||||
|
||||
#smart_editor2 .se2_quote .hover button span, #smart_editor2 .se2_quote .active button span { width: 30px; height: 30px; margin: 0; padding: 0; border: 2px solid #44b525; }
|
||||
|
||||
#smart_editor2 .se2_quote .hover button span span, #smart_editor2 .se2_quote .active button span span { visibility: hidden; overflow: hidden; position: absolute; top: 0; left: 0; width: 0; height: 0; margin: 0; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_quote .se2_cancel2 { float: left; width: 40px; height: 35px; margin: 11px 0 0 5px; background: url("../img/ko_KR/btn_set.png?130306") -46px -24px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_quote .se2_cancel2 span { visibility: hidden; overflow: hidden; position: absolute; top: 0; left: 0; width: 0; height: 0; margin: 0; padding: 0; }
|
||||
|
||||
/* TEXT_TOOLBAR : HYPERLINK */
|
||||
#smart_editor2 .se2_url2 { width: 281px; padding: 11px 11px 6px 11px; color: #666; }
|
||||
|
||||
#smart_editor2 .se2_url2 .input_ty1 { display: block; width: 185px; height: 16px; margin: 0 5px 5px 0; *margin: -1px 5px 5px 0; padding: 5px 2px 0 4px; }
|
||||
|
||||
#smart_editor2 .se2_url2 .se2_url_new { width: 15px; height: 15px; margin: -1px 3px 1px -1px; *margin: -2px 3px 2px -1px; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_url2 label { font-size: 11px; line-height: 14px; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_url2 .se2_apply { position: absolute; top: 13px; right: 51px; width: 41px; height: 24px; margin: -1px 3px 1px 0; background: url("../img/ko_KR/btn_set.png?130306") no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_url2 .se2_cancel { position: absolute; top: 13px; right: 9px; width: 39px; height: 24px; margin: -1px 3px 1px 0; background: url("../img/ko_KR/btn_set.png?130306") -41px 0 no-repeat; }
|
||||
|
||||
/* TEXT_TOOLBAR : SCHARACTER */
|
||||
#smart_editor2 .se2_bx_character { width: 469px; height: 272px; margin: 0; padding: 0; background: url("../img/ko_KR/bx_set_110302.gif") 9px -1230px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_char_tab { _display: inline; float: left; position: relative; width: 443px; margin: 11px 10px 200px 11px; padding: 0 0 0 1px; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_char_tab li { position: static; margin: 0 0 0 -1px; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_char1 { width: 76px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") 0 -204px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_char2 { width: 86px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") -75px -204px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_char3 { width: 68px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") -160px -204px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_char4 { width: 55px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") -227px -204px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_char5 { width: 97px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") -281px -204px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_char6 { width: 66px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") -377px -204px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .active .se2_char1 { width: 76px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") 0 -230px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .active .se2_char2 { width: 86px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") -75px -230px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .active .se2_char3 { width: 68px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") -160px -230px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .active .se2_char4 { width: 55px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") -227px -230px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .active .se2_char5 { width: 97px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") -281px -230px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .active .se2_char6 { width: 66px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") -377px -230px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_s_character { display: none; position: absolute; top: 26px; left: 0; width: 448px; height: 194px; margin: 0; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .active .se2_s_character { display: block; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_s_character ul { float: left; width: 422px; height: 172px; margin: 0; padding: 9px 0 0 11px; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_s_character li { _display: inline; float: left; position: relative; width: 20px; height: 18px; margin: 0 0 1px 1px; background: #fff; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_s_character button { width: 20px; height: 18px; margin: 0; padding: 2px; background: none; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_s_character .hover, #smart_editor2 .se2_bx_character .se2_s_character .active { background: url("../img/ko_KR/btn_set.png?130306") -446px -274px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_character .se2_s_character button span { left: 0; display: block; visibility: visible; overflow: visible; width: 14px; height: 16px; margin: 3px 0 0 3px; border: 0; background: none; font-size: 12px; line-height: normal; }
|
||||
|
||||
#smart_editor2 .se2_apply_character { clear: both; position: relative; padding: 0 0 0 11px; }
|
||||
|
||||
#smart_editor2 .se2_apply_character label { margin: 0 3px 0 0; font-size: 12px; color: #666; letter-spacing: -1px; }
|
||||
|
||||
#smart_editor2 .se2_apply_character .input_ty1 { width: 283px; height: 17px; margin: -1px 5px 1px 0; padding: 4px 0 0 5px; font-size: 12px; color: #666; letter-spacing: 0; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_apply_character .se2_confirm { width: 41px; height: 24px; margin-right: 3px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_apply_character .se2_cancel { width: 39px; height: 24px; background: url("../img/ko_KR/btn_set.png?130306") -41px 0 no-repeat; vertical-align: middle; }
|
||||
|
||||
/* TEXT_TOOLBAR : TABLECREATOR */
|
||||
#smart_editor2 .se2_table_set { position: relative; width: 166px; margin: 3px 11px 0 11px; padding: 8px 0 0 0; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_cell_num { float: left; width: 73px; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_cell_num dt { float: left; clear: both; width: 17px; height: 23px; margin: 0; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_cell_num dt label { display: block; margin: 5px 0 0 0; font-size: 11px; color: #666; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_cell_num dd { float: left; position: relative; width: 54px; height: 23px; margin: 0; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_cell_num .input_ty2 { display: block; width: 32px; height: 16px; *margin: -1px 0 0 0; padding: 2px 19px 0 0px; border: 1px solid #c7c7c7; font-family: tahoma,verdana,times New Roman; font-size: 11px; color: #666; text-align: right; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_cell_num .input_ty2::-ms-clear { display: none; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_pre_table { float: right; width: 91px; height: 43px; background: #c7c7c7; border-spacing: 1px; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_pre_table tr { background: #fff; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_pre_table td { font-size: 0; line-height: 0; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_add { position: absolute; top: 2px; right: 3px; width: 13px; height: 8px; background: url("../img/ko_KR/btn_set.png?130306") -86px -54px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_del { position: absolute; top: 10px; right: 3px; width: 13px; height: 8px; background: url("../img/ko_KR/btn_set.png?130306") -86px -62px no-repeat; }
|
||||
|
||||
/* TEXT_TOOLBAR : TABLEEDITOR */
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1 { float: left; width: 166px; margin: 7px 0 0 0; padding: 10px 0 5px; background: url("../img/bg_line1.gif") repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1 dt { width: 166px; margin: 0 0 6px 0; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1 dd { width: 166px; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1 dt input { width: 15px; height: 15px; margin: -1px 3px 1px 0; _margin: -2px 3px 2px 0; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1 dt label { font-weight: bold; font-size: 11px; color: #666; letter-spacing: -1px; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1_1 { float: left; position: relative; z-index: 59; width: 166px; margin: 1px 0 0 0; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1_2 { z-index: 54; margin: 0; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1_3 { z-index: 53; margin: 0; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1_4 { z-index: 52; margin: 0; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1_1 dt { _display: inline; float: left; clear: both; width: 66px; height: 22px; margin: 1px 0 0 18px; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1_1 dt label { display: block; margin: 4px 0 0 0; font-weight: normal; font-size: 11px; color: #666; letter-spacing: -1px; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1_1 dd { float: left; position: relative; width: 82px; height: 23px; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1_1 .input_ty1 { width: 72px; height: 16px; *margin: -1px 0 0 0; padding: 2px 2px 0 6px; font-family: tahoma,verdana,times New Roman; font-size: 11px; color: #666; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1_1 .input_ty3 { float: left; width: 49px; height: 16px; margin: 0 3px 0 0; padding: 2px 4px 0 4px; border: 1px solid #c7c7c7; font-family: tahoma,verdana,times New Roman; font-size: 11px; color: #666; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1_1 .se2_add { top: 2px; right: 2px; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1_1 .se2_del { top: 10px; right: 2px; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper1_1 .se2_color_set .input_ty1 { _display: inline; float: left; width: 67px; height: 16px; margin: 0 3px 0 3px; padding: 2px 2px 0 4px; font-family: tahoma,verdana,times New Roman; font-size: 11px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty1 { position: relative; width: 80px; height: 18px; border: 1px solid #c7c7c7; background: #fff; font-size: 11px; line-height: 14px; text-align: left; }
|
||||
|
||||
#smart_editor2 .se2_select_ty1 span { float: left; width: 54px; height: 18px; margin: 0 0 0 5px; font-size: 11px; line-height: 14px; color: #666; }
|
||||
|
||||
#smart_editor2 .se2_select_ty1 .se2_b_style0 { position: relative; top: 3px; left: -3px; white-space: nowrap; }
|
||||
|
||||
#smart_editor2 .se2_select_ty1 .se2_b_style1 { height: 15px; margin: 3px 0 0 4px; font-size: 11px; line-height: 14px; color: #666; letter-spacing: -1px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty1 .se2_b_style2 { background: url("../img/bg_set.gif") 0 -50px repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_select_ty1 .se2_b_style3 { background: url("../img/bg_set.gif") 0 -68px repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_select_ty1 .se2_b_style4 { background: url("../img/bg_set.gif") 0 -85px repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_select_ty1 .se2_b_style5 { background: url("../img/bg_set.gif") 0 -103px repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_select_ty1 .se2_b_style6 { background: url("../img/bg_set.gif") 0 -121px repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_select_ty1 .se2_b_style7 { background: url("../img/bg_set.gif") 0 -139px repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_select_ty1 .se2_view_more { position: absolute; top: 1px; right: 1px; width: 13px; height: 16px; background: url("../img/ko_KR/btn_set.png?130306") -112px -54px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_select_ty1 .se2_view_more2 { position: absolute; top: 1px; right: 1px; width: 13px; height: 16px; background: url("../img/ko_KR/btn_set.png?130306") -99px -54px no-repeat; }
|
||||
|
||||
/* TEXT_TOOLBAR : TABLEEDITOR > BORDER */
|
||||
#smart_editor2 .se2_table_set .se2_b_t_b1 { border-top: 1px solid #b1b1b1; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style { position: absolute; top: 20px; right: 0px; width: 80px; padding-bottom: 1px; border: 1px solid #c7c7c7; border-top: 1px solid #a8a8a8; background: #fff; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style ul { width: 80px; margin: 0; padding: 1px 0 0 0; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style li { width: 80px; height: 18px; margin: 0; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style .hover, #smart_editor2 .se2_layer_b_style .active { background: #ebebeb; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style button { width: 80px; height: 18px; background: none; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style button span { left: 0; display: block; visibility: visible; overflow: visible; width: 71px; height: 18px; margin: 0 0 0 5px; font-size: 11px; line-height: 15px; text-align: left; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style button span span { visibility: hidden; overflow: hidden; position: absolute; top: 0; left: 0; width: 0; height: 0; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style .se2_b_style1 span { margin: 3px 0 0 4px; font-size: 11px; line-height: 14px; color: #666; letter-spacing: -1px; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style .se2_b_style2 span { background: url("../img/bg_set.gif") 0 -50px repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style .se2_b_style3 span { background: url("../img/bg_set.gif") 0 -68px repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style .se2_b_style4 span { background: url("../img/bg_set.gif") 0 -86px repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style .se2_b_style5 span { background: url("../img/bg_set.gif") 0 -103px repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style .se2_b_style6 span { background: url("../img/bg_set.gif") 0 -121px repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_layer_b_style .se2_b_style7 span { background: url("../img/bg_set.gif") 0 -139px repeat-x; }
|
||||
|
||||
/* TEXT_TOOLBAR : TABLEEDITOR > COLOR */
|
||||
#smart_editor2 .se2_pre_color { float: left; width: 18px; height: 18px; border: 1px solid #c7c7c7; }
|
||||
|
||||
#smart_editor2 .se2_pre_color button { float: left; width: 14px; height: 14px; margin: 2px 0 0 2px; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_pre_color button span { overflow: hidden; position: absolute; top: -10000px; left: -10000px; z-index: -100; width: 0; height: 0; }
|
||||
|
||||
/* TEXT_TOOLBAR : TABLEEDITOR > DIMMED */
|
||||
#smart_editor2 .se2_table_set .se2_t_dim1 { clear: both; position: absolute; top: 71px; left: 16px; z-index: 60; width: 157px; height: 118px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_dim2 { position: absolute; top: 116px; left: 16px; z-index: 55; width: 157px; height: 45px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_dim3 { clear: both; position: absolute; top: 192px; left: 16px; z-index: 51; width: 157px; height: 39px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
/* TEXT_TOOLBAR : TABLEEDITOR > STYLE PREVIEW */
|
||||
#smart_editor2 .se2_table_set .se2_t_proper2 { float: left; position: relative; z-index: 50; width: 166px; margin: 2px 0 0 0; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper2 dt { float: left; width: 84px; height: 33px; margin: 4px 0 0 0; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper2 dt input { width: 15px; height: 15px; margin: -1px 3px 1px 0; _margin: -2px 3px 2px 0; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper2 dt label { font-weight: bold; font-size: 11px; color: #666; letter-spacing: -1px; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_t_proper2 dd { float: left; width: 66px; height: 33px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 { position: relative; width: 65px; height: 31px; border: 1px solid #c7c7c7; background: #fff; font-size: 11px; line-height: 14px; text-align: left; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 span { float: left; width: 45px; height: 25px; margin: 3px 0 0 3px; background: url("../img/ko_KR/btn_set.png?130306") repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style1 { background-position: 0 -410px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style2 { background-position: -46px -410px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style3 { background-position: -92px -410px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style4 { background-position: -138px -410px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style5 { background-position: -184px -410px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style6 { background-position: -230px -410px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style7 { background-position: -276px -410px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style8 { background-position: -322px -410px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style9 { background-position: 0 -436px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style10 { background-position: -46px -436px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style11 { background-position: -92px -436px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style12 { background-position: -138px -436px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style13 { background-position: -184px -436px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style14 { background-position: -230px -436px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style15 { background-position: -276px -436px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_t_style16 { background-position: -322px -436px; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_view_more { position: absolute; top: 1px; right: 1px; _right: 0px; width: 13px !important; height: 29px !important; background: url("../img/ko_KR/btn_set.png?130306") -353px -48px no-repeat !important; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_view_more2 { position: absolute; top: 1px; right: 1px; _right: 0px; width: 13px !important; height: 29px !important; background: url("../img/ko_KR/btn_set.png?130306") -340px -48px no-repeat !important; }
|
||||
|
||||
#smart_editor2 .se2_select_ty2 .se2_view_more span { display: none; }
|
||||
|
||||
/* TEXT_TOOLBAR : TABLEEDITOR > STYLE */
|
||||
#smart_editor2 .se2_layer_t_style { position: absolute; top: 33px; right: 15px; width: 208px; border: 1px solid #c7c7c7; border-top: 1px solid #a8a8a8; background: #fff; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style ul { width: 204px; height: 126px; margin: 1px 2px; padding: 1px 0 0 0; background: #fff; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style li { _display: inline; float: left; width: 45px; height: 25px; margin: 1px; padding: 1px; border: 1px solid #fff; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .hover, #smart_editor2 .se2_layer_t_style .active { border: 1px solid #666; background: #fff; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style button { width: 45px; height: 25px; background: url("../img/ko_KR/btn_set.png?130306") repeat-x !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style1 { background-position: 0 -410px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style2 { background-position: -46px -410px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style3 { background-position: -92px -410px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style4 { background-position: -138px -410px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style5 { background-position: -184px -410px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style6 { background-position: -230px -410px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style7 { background-position: -276px -410px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style8 { background-position: -322px -410px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style9 { background-position: 0 -436px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style10 { background-position: -46px -436px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style11 { background-position: -92px -436px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style12 { background-position: -138px -436px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style13 { background-position: -184px -436px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style14 { background-position: -230px -436px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style15 { background-position: -276px -436px !important; }
|
||||
|
||||
#smart_editor2 .se2_layer_t_style .se2_t_style16 { background-position: -322px -436px !important; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_btn_area { float: left; width: 166px; margin: 6px 0 0 0; padding: 12px 0 8px 0; background: url("../img/bg_line1.gif") repeat-x; text-align: center; }
|
||||
|
||||
#smart_editor2 .se2_table_set button.se2_apply { width: 41px; height: 24px; margin-right: 3px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_table_set button.se2_cancel { width: 39px; height: 24px; background: url("../img/ko_KR/btn_set.png?130306") -41px 0 no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_rd { width: 14px; height: 14px; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_table_set .se2_celltit { font-size: 11px; font-size: 11px; color: #666; letter-spacing: -1px; }
|
||||
|
||||
#smart_editor2 .se2_table_set dt label.se2_celltit { display: inline; }
|
||||
|
||||
/* TEXT_TOOLBAR : FINDREPLACE */
|
||||
#smart_editor2 .se2_bx_find_revise { position: relative; width: 255px; margin: 0; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .se2_close { position: absolute; top: 5px; right: 8px; width: 20px; height: 20px; background: url("../img/ko_KR/btn_set.png?130306") -151px -1px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise h3 { margin: 0; padding: 10px 0 13px 10px; background: url("../img/bg_find_h3.gif") 0 -1px repeat-x; font-size: 12px; line-height: 14px; letter-spacing: -1px; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise ul { position: relative; margin: 8px 0 0 0; padding: 0 0 0 12px; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise ul li { _display: inline; float: left; position: static; margin: 0 0 0 -1px; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .se2_tabfind { width: 117px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") 0 -100px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .se2_tabrevise { width: 117px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") -116px -100px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .active .se2_tabfind { width: 117px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") 0 -126px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .active .se2_tabrevise { width: 117px; height: 26px; background: url("../img/ko_KR/btn_set.png?130306") -116px -126px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .se2_in_bx_find dl { _display: inline; float: left; width: 223px; margin: 0 0 0 9px; padding: 7px 0 13px 14px; background: url("../img/ko_KR/bx_set_110302.gif") -289px -1518px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .se2_in_bx_revise dl { _display: inline; float: left; width: 223px; margin: 0 0 0 9px; padding: 7px 0 13px 14px; background: url("../img/ko_KR/bx_set_110302.gif") -289px -1619px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise dt { _display: inline; float: left; clear: both; width: 47px; margin: 1px 0 2px 0; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise dd { float: left; margin: 0 0 2px 0; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise label { float: left; padding: 5px 0 0 0; font-size: 11px; color: #666; letter-spacing: -2px; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise input { float: left; width: 155px; height: 12px; margin: 1px 0 0 0; padding: 3px 2px 3px 4px; font-size: 12px; color: #666; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .se2_find_btns { float: left; clear: both; width: 255px; padding: 8px 0 10px 0; text-align: center; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .se2_find_next { width: 65px; height: 24px; margin: 0 3px 0 0; background: url("../img/ko_KR/btn_set.png?130306") -180px -48px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .se2_find_next2 { width: 61px; height: 24px; margin: 0 3px 0 0; background: url("../img/ko_KR/btn_set.png?130306") -180px -24px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .se2_revise1 { width: 54px; height: 24px; margin: 0 3px 0 0; background: url("../img/ko_KR/btn_set.png?130306") -245px -48px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .se2_revise2 { width: 70px; height: 24px; margin: 0 3px 0 0; background: url("../img/ko_KR/btn_set.png?130306") -245px -24px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_bx_find_revise .se2_cancel { width: 39px; height: 24px; background: url("../img/ko_KR/btn_set.png?130306") -41px 0 no-repeat; }
|
||||
|
||||
/* TEXT_TOOLBAR : QUICKEDITOR_TABLE */
|
||||
#smart_editor2 .se2_qmax { position: absolute; width: 18px; height: 18px; background: url("../img/ko_KR/btn_set.png?130306") -339px -169px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_qeditor { position: absolute; top: 0; left: 0; width: 183px; margin: 0; padding: 0; border: 1px solid #c7c7c7; border-right: 1px solid #ababab; border-bottom: 1px solid #ababab; background: #fafafa; }
|
||||
|
||||
#smart_editor2 .se2_qeditor label, #smart_editor2 .se2_qeditor span, #smart_editor2 .se2_qeditor dt { font-size: 11px; color: #666; letter-spacing: -1px; }
|
||||
|
||||
#smart_editor2 .se2_qbar { position: relative; width: 183px; height: 11px; background: url("../img/ko_KR/bx_set_110302.gif") 0 -731px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_qbar .se2_qmini { position: absolute; top: -1px; right: 0; *right: -1px; _right: -3px; width: 18px; height: 14px; background: url("../img/ko_KR/btn_set.png?130306") -315px -170px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_qbar .se2_qmini button { width: 20px; height: 14px; margin-top: -1px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qbody0 { float: left; border: 1px solid #fefefe; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qbody { position: relative; z-index: 90; width: 174px; padding: 4px 0 0 7px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe1 { overflow: hidden; width: 174px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe1 dt { float: left; width: 22px; height: 18px; padding: 4px 0 0 0; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe1 dd { float: left; width: 65px; height: 22px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_addrow { width: 28px; height: 19px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat -385px -49px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_addcol { width: 29px; height: 19px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat -413px -49px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_seprow { width: 28px; height: 19px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat -385px -68px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_sepcol { width: 29px; height: 19px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat -413px -68px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_delrow { width: 28px; height: 19px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat -385px -106px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_delcol { width: 29px; height: 19px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat -413px -106px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_merrow { width: 57px; height: 19px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat -385px -125px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_mercol { width: 57px; height: 19px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat -413px -125px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_seprow_off { width: 28px; height: 19px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat -385px -87px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_sepcol_off { width: 29px; height: 19px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat -413px -87px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_merrow_off { width: 57px; height: 19px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat -385px -144px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_mercol_off { width: 57px; height: 19px; background: url("../img/ko_KR/btn_set.png?130306") no-repeat -413px -144px; }
|
||||
|
||||
/* TEXT_TOOLBAR : QUICKEDITOR_TABLE > CELL_BACKGROUND */
|
||||
#smart_editor2 .se2_qeditor .se2_qe2 { _display: inline; float: left; position: relative; z-index: 100; width: 165px; margin: 2px 0 0 1px; padding: 7px 0 0 0; background: url("../img/bg_line1.gif") repeat-x; zoom: 1; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_1 dt { float: left; width: 62px; padding: 3px 0 0 0; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_1 dt input { width: 15px; height: 15px; margin: -1px 1px 1px -1px; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_1 dd { float: left; position: relative; zoom: 1; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_3 { padding: 7px 0 6px 0; }
|
||||
|
||||
/* My글양식 없을때 */
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 { position: relative; _position: absolute; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 dt { float: left; width: 50px; padding: 3px 0 0 13px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 dt input { width: 15px; height: 15px; margin: -1px 2px 1px -1px; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 dd { float: left; }
|
||||
|
||||
/* TEXT_TOOLBAR : QUICKEDITOR_TABLE > STYLE */
|
||||
#smart_editor2 .se2_table_set .se2_qbody .se2_t_proper2 { float: left; *float: none; position: static; width: 166px; margin: 5px 0 0 1px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe3 dt { float: left; width: 62px; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe3 dt label { font-weight: normal; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe3 dt input { width: 15px; height: 15px; margin: -1px 1px 1px -1px; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe3 dd .se2_qe3_table { position: relative; }
|
||||
|
||||
/* TEXT_TOOLBAR : QUICKEDITOR_TABLE > CELL_BACKGROUND PREWVIEW */
|
||||
#smart_editor2 .se2_qeditor .se2_pre_color { float: left; width: 18px; height: 18px; border: 1px solid #c7c7c7; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_color button { float: left; width: 14px; height: 14px; margin: 2px 0 0 2px; padding: 0; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_color button span { overflow: hidden; position: absolute; top: -10000px; left: -10000px; z-index: -100; width: 0; height: 0; }
|
||||
|
||||
/* TEXT_TOOLBAR : QUICKEDITOR_TABLE > CELL_BACKGROUND LAYER */
|
||||
#smart_editor2 .se2_qeditor .se2_layer { float: left; clear: both; position: absolute; top: 20px; left: 0; margin: 0; padding: 0; border: 1px solid #c7c7c7; border-top: 1px solid #9a9a9a; background: #fafafa; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_layer .se2_in_layer { float: left; margin: 0; padding: 0; border: 1px solid #fff; background: #fafafa; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_layer button { vertical-align: top; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_layer .se2_pick_color li { position: relative; }
|
||||
|
||||
/* TEXT_TOOLBAR : QUICKEDITOR_TABLE > CELL_BACKGROUND IMAGE */
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg { float: left; width: 14px; height: 14px; padding: 2px; border: 1px solid #c7c7c7; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 button { width: 16px; height: 16px; background: url("../img/ko_KR/btn_set.png?130306") 0 -261px no-repeat; }
|
||||
|
||||
/* TEXT_TOOLBAR : QUICKEDITOR_TABLE > CELL_BACKGROUND IMAGE LAYER */
|
||||
#smart_editor2 .se2_cellimg_set { _display: inline; float: left; width: 136px; margin: 4px 3px 0 4px; padding-bottom: 4px; }
|
||||
|
||||
#smart_editor2 .se2_cellimg_set li { _display: inline; float: left; width: 16px; height: 16px; margin: 0 1px 1px 0; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg0 { background-position: -255px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg1 { background-position: 0 -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg2 { background-position: -17px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg3 { background-position: -34px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg4 { background-position: -51px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg5 { background-position: -68px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg6 { background-position: -85px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg7 { background-position: -102px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg8 { background-position: -119px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg9 { background-position: -136px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg10 { background-position: -153px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg11 { background-position: -170px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg12 { background-position: -187px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg13 { background-position: -204px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg14 { background-position: -221px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg15 { background-position: -238px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg16 { background-position: -255px -261px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg17 { background-position: 0 -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg18 { background-position: -17px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg19 { background-position: -34px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg20 { background-position: -51px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg21 { background-position: -68px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg22 { background-position: -85px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg23 { background-position: -102px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg24 { background-position: -119px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg25 { background-position: -136px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg26 { background-position: -153px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg27 { background-position: -170px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg28 { background-position: -187px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg29 { background-position: -204px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg30 { background-position: -221px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qe2_2 .se2_cellimg31 { background-position: -238px -278px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg button { width: 14px; height: 14px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg1 { background-position: -1px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg2 { background-position: -18px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg3 { background-position: -35px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg4 { background-position: -52px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg5 { background-position: -69px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg6 { background-position: -86px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg7 { background-position: -103px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg8 { background-position: -120px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg9 { background-position: -137px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg10 { background-position: -154px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg11 { background-position: -171px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg12 { background-position: -188px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg13 { background-position: -205px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg14 { background-position: -222px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg15 { background-position: -239px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg16 { background-position: -256px -262px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg17 { background-position: -1px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg18 { background-position: -18px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg19 { background-position: -35px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg20 { background-position: -52px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg21 { background-position: -69px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg22 { background-position: -86px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg23 { background-position: -103px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg24 { background-position: -120px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg25 { background-position: -137px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg26 { background-position: -154px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg27 { background-position: -171px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg28 { background-position: -188px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg29 { background-position: -205px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg30 { background-position: -222px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg31 { background-position: -239px -279px; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_pre_bgimg .se2_cellimg32 { background-position: -256px -279px; }
|
||||
|
||||
/* TEXT_TOOLBAR : QUICKEDITOR_TABLE > MY REVIEW */
|
||||
#smart_editor2 .se2_btn_area { _display: inline; float: left; clear: both; width: 166px; margin: 5px 0 0 1px; padding: 7px 0 6px 0; background: url("../img/bg_line1.gif") repeat-x; text-align: center; }
|
||||
|
||||
#smart_editor2 .se2_btn_area .se2_btn_save { width: 97px; height: 21px; background: url("../img/ko_KR/btn_set.png?130306") -369px -163px no-repeat; }
|
||||
|
||||
/* TEXT_TOOLBAR : QUICKEDITOR_IMAGE */
|
||||
#smart_editor2 .se2_qe10 { width: 166px; margin: 0; *margin: -2px 0 0 0; }
|
||||
|
||||
#smart_editor2 .se2_qe10 label { margin: 0 1px 0 0; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_qe10 .se2_sheight { margin-left: 4px; }
|
||||
|
||||
#smart_editor2 .se2_qe10 .input_ty1 { width: 30px; height: 13px; margin: 0 0 1px 1px; padding: 3px 4px 0 1px; font-size: 11px; letter-spacing: 0; text-align: right; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_qe10 .se2_sreset { width: 41px; height: 19px; margin-left: 3px; background: url("../img/ko_KR/btn_set.png?130306") -401px -184px no-repeat; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_qe10_1 { margin-top: 4px; padding: 10px 0 3px; background: url("../img/bg_line1.gif") repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_qe10_1 input { width: 15px; height: 15px; margin: -1px 3px 1px -1px; vertical-align: middle; }
|
||||
|
||||
#smart_editor2 .se2_qe11 { float: left; width: 166px; margin: 4px 0 0 0; padding: 7px 0 2px 0; background: url("../img/bg_line1.gif") repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_qe11_1 { float: left; width: 99px; }
|
||||
|
||||
#smart_editor2 .se2_qe11_1 dt { float: left; width: 56px; height: 15px; padding: 5px 0 0 0; }
|
||||
|
||||
#smart_editor2 .se2_qe11_1 dd { float: left; position: relative; width: 38px; height: 20px; }
|
||||
|
||||
#smart_editor2 .se2_qe11_1 .input_ty1 { display: block; width: 29px; height: 15px; margin: 0; *margin: -1px 0 1px 0; padding: 3px 1px 0 5px; font-size: 11px; letter-spacing: 0; text-align: left; }
|
||||
|
||||
#smart_editor2 .se2_qe11_1 .se2_add { position: absolute; top: 2px; right: 3px; width: 13px; height: 8px; background: url("../img/ko_KR/btn_set.png?130306") -86px -54px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_qe11_1 .se2_del { position: absolute; top: 10px; right: 3px; width: 13px; height: 8px; background: url("../img/ko_KR/btn_set.png?130306") -86px -62px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_qe11_2 { float: left; width: 67px; }
|
||||
|
||||
#smart_editor2 .se2_qe11_2 dt { float: left; width: 47px; margin: 5px 0 0 0; }
|
||||
|
||||
#smart_editor2 .se2_qe11_2 dd { float: left; position: relative; width: 20px; }
|
||||
|
||||
#smart_editor2 .se2_qe12 { float: left; width: 166px; margin: 3px 0 0 0; padding: 7px 0 0 0; background: url("../img/bg_line1.gif") repeat-x; }
|
||||
|
||||
#smart_editor2 .se2_qe12 dt { float: left; margin: 5px 4px 0 0; }
|
||||
|
||||
#smart_editor2 .se2_qe12 dd { float: left; padding: 0 0 6px 0; }
|
||||
|
||||
#smart_editor2 .se2_qe12 .se2_align0 { float: left; width: 19px; height: 21px; background: url("../img/ko_KR/btn_set.png?130306") -276px -121px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_qe12 .se2_align1 { float: left; width: 19px; height: 21px; background: url("../img/ko_KR/btn_set.png?130306") -295px -121px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_qe12 .se2_align2 { float: left; width: 20px; height: 21px; background: url("../img/ko_KR/btn_set.png?130306") -314px -121px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_qe13 { position: relative; z-index: 10; zoom: 1; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dt { float: left; width: 62px; padding: 3px 0 0; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dt input { width: 15px; height: 15px; margin: -1px 1px 1px -1px; vertical-align: middle; zoom: 1; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dt .se2_qdim2 { width: 32px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dd .se2_select_ty1 { width: 38px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dd .se2_select_ty1 span { width: 15px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dd .input_ty1 { width: 20px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dd .se2_palette2 .input_ty1 { width: 67px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 .se2_add { *top: 3px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 .se2_del { *top: 11px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 .se2_layer_b_style { right: -2px; _right: 0; }
|
||||
|
||||
#smart_editor2 .se2_qe13 .se2_layer_b_style li span { width: auto; margin: 0 4px 0 5px; padding-top: 2px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dd { _display: inline; float: left; position: relative; width: 29px; margin-right: 5px; _margin-right: 3px; zoom: 1; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dd .se2_palette h4 { margin-top: 9px; font-family: dotum; font-size: 12px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dd.dd_type { width: 38px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dd.dd_type2 { width: 37px; margin-right: 3px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dd.dd_type2 .input_ty1 { width: 29px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dd.dd_type2 button { right: 2px; _right: 1px; }
|
||||
|
||||
#smart_editor2 .se2_qe13 dd.dd_type3 { width: 20px; margin: 0; }
|
||||
|
||||
#smart_editor2 .se2_qe13_v1 { _display: inline; float: left; margin: 2px 0 1px; }
|
||||
|
||||
#smart_editor2 .se2_qe13_v1 dt { padding: 4px 0 0 1px; }
|
||||
|
||||
#smart_editor2 .se2_qe13_v2 { _display: inline; float: left; position: relative; z-index: 100; width: 165px; margin: 4px 0 0 1px; zoom: 1; }
|
||||
|
||||
#smart_editor2 .se2_qe13_v2 dd { width: 18px; margin: 0; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qdim1 { clear: both; position: absolute; top: 25px; left: 115px; width: 60px; height: 23px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qdim2 { clear: both; position: absolute; top: 55px; left: 24px; z-index: 110; width: 70px; height: 22px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qdim3 { clear: both; position: absolute; top: 55px; left: 118px; z-index: 110; width: 56px; height: 22px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qdim4 { clear: both; position: absolute; top: 81px; left: 23px; z-index: 35; width: 116px; height: 35px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qdim5 { clear: both; position: absolute; top: 31px; left: 106px; width: 68px; height: 26px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qdim6c { clear: both; position: absolute; top: 25px; left: 28px; width: 29px; height: 23px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qdim6r { clear: both; position: absolute; top: 25px; left: 57px; width: 29px; height: 23px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_highedit { float: right; width: 56px; height: 21px; margin: -27px 8px 0 0; background: url("../img/ko_KR/btn_set.png?130306") -329px -142px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qdim7 { clear: both; position: absolute; top: 55px; left: 24px; z-index: 110; width: 150px; height: 48px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qdim8 { clear: both; position: absolute; top: 105px; left: 24px; z-index: 110; width: 150px; height: 37px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qdim9 { clear: both; position: absolute; top: 55px; left: 111px; z-index: 110; width: 65px; height: 24px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qdim10 { clear: both; position: absolute; top: 55px; left: 100px; z-index: 110; width: 77px; height: 24px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
#smart_editor2 .se2_qeditor .se2_qdim11 { clear: both; position: absolute; top: 55px; left: 65px; z-index: 110; width: 115px; height: 24px; background: #fafafa; opacity: 0.5; filter: alpha(opacity=50); }
|
||||
|
||||
/* HELP : ACCESSIBILITY */
|
||||
#smart_editor2 .se2_accessibility { z-index: 90; }
|
||||
|
||||
#smart_editor2 .se2_accessibility .se2_in_layer { width: 568px; padding: 0 10px; background: #fafafa; border: 1px solid #bcbbbb; }
|
||||
|
||||
#smart_editor2 .se2_accessibility h3 { margin: 0 -10px; padding: 6px 0 12px 0; background: url("../img/bg_find_h3.gif") repeat-x; font-size: 12px; line-height: 14px; letter-spacing: -1px; }
|
||||
|
||||
#smart_editor2 .se2_accessibility h3 strong { display: inline-block; padding: 4px 0 3px 11px; color: #333; letter-spacing: 0; }
|
||||
|
||||
#smart_editor2 .se2_accessibility .se2_close { position: absolute; top: 10px; right: 12px; width: 13px; height: 12px; background: url("../img/ko_KR/btn_set.png?130306") -155px -5px no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_accessibility .box_help { padding: 0 2px; margin-top: 8px; background: url("../img/bg_help.gif") 0 100% no-repeat; }
|
||||
|
||||
#smart_editor2 .se2_accessibility .box_help div { overflow: hidden; padding: 20px 21px 24px; border-top: 1px solid #d0d0d0; color: #333; }
|
||||
|
||||
#smart_editor2 .se2_accessibility .box_help strong { display: block; margin-bottom: 2px; }
|
||||
|
||||
#smart_editor2 .se2_accessibility .box_help p { margin-bottom: 28px; line-height: 1.5; }
|
||||
|
||||
#smart_editor2 .se2_accessibility .box_help ul { width: 150%; margin-top: 10px; }
|
||||
|
||||
#smart_editor2 .se2_accessibility .box_help li { position: relative; float: left; width: 252px; padding: 5px 0 5px 9px; margin-right: 40px; background: url("../img/ko_KR/btn_set.png?130306") -475px -51px no-repeat; border-right: 1px solid #f0f0f0; *zoom: 1; line-height: 1; }
|
||||
|
||||
#smart_editor2 .se2_accessibility .box_help li span { position: absolute; top: 4px; left: 138px; line-height: 1.2; }
|
||||
|
||||
#smart_editor2 .se2_accessibility .se2_btns { padding: 9px 0 10px; text-align: center; }
|
||||
|
||||
#smart_editor2 .se2_accessibility .se2_btns .se2_close2 { width: 39px; height: 24px; background: url("../img/ko_KR/btn_set.png?130306") -235px -120px no-repeat; }
|
||||
@@ -0,0 +1,20 @@
|
||||
@charset "UTF-8";
|
||||
/* NHN Web Standardization Team (http://html.nhndesign.com/) HHJ 090226 */
|
||||
/* COMMON */
|
||||
.se2_outputarea, .se2_outputarea th, .se2_outputarea td { margin: 0; padding: 0; color: #666; font-size: 12px; font-family: '돋움',Dotum,'굴림',Gulim,Helvetica,Sans-serif; line-height: 1.5; }
|
||||
|
||||
.se2_outputarea p { margin: 0; padding: 0; }
|
||||
|
||||
.se2_outputarea a:hover { text-decoration: underline; }
|
||||
|
||||
.se2_outputarea a:link { color: #0000ff; }
|
||||
|
||||
.se2_outputarea ul { margin: 0 0 0 40px; padding: 0; }
|
||||
|
||||
.se2_outputarea ul li { margin: 0; list-style-type: disc; padding: 0; }
|
||||
|
||||
.se2_outputarea ul ul li { list-style-type: circle; }
|
||||
|
||||
.se2_outputarea ul ul ul li { list-style-type: square; }
|
||||
|
||||
.se2_outputarea img, .se2_outputarea fieldset { border: 0; }
|
||||
@@ -0,0 +1,67 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
|
||||
function editor_html($id, $content, $is_dhtml_editor=true)
|
||||
{
|
||||
global $g5, $config;
|
||||
static $js = true;
|
||||
|
||||
$editor_url = G5_EDITOR_URL.'/'.$config['cf_editor'];
|
||||
|
||||
$html = "";
|
||||
$html .= "<span class=\"sound_only\">웹에디터 시작</span>";
|
||||
if ($is_dhtml_editor)
|
||||
$html .= '<script>document.write("<div class=\'cke_sc\'><button type=\'button\' class=\'btn_cke_sc\'>단축키 일람</button></div>");</script>';
|
||||
|
||||
if ($is_dhtml_editor && $js) {
|
||||
$html .= "\n".'<script src="'.$editor_url.'/js/HuskyEZCreator.js"></script>';
|
||||
$html .= "\n".'<script>var g5_editor_url = "'.$editor_url.'", oEditors = [];</script>';
|
||||
$html .= "\n".'<script src="'.$editor_url.'/config.js"></script>';
|
||||
$html .= "\n<script>";
|
||||
$html .= '
|
||||
$(function(){
|
||||
$(".btn_cke_sc").click(function(){
|
||||
if ($(this).next("div.cke_sc_def").length) {
|
||||
$(this).next("div.cke_sc_def").remove();
|
||||
$(this).text("단축키 일람");
|
||||
} else {
|
||||
$(this).after("<div class=\'cke_sc_def\' />").next("div.cke_sc_def").load("'.$editor_url.'/shortcut.html");
|
||||
$(this).text("단축키 일람 닫기");
|
||||
}
|
||||
});
|
||||
$(".btn_cke_sc_close").live("click",function(){
|
||||
$(this).parent("div.cke_sc_def").remove();
|
||||
});
|
||||
});';
|
||||
$html .= "\n</script>";
|
||||
$js = false;
|
||||
}
|
||||
|
||||
$smarteditor_class = $is_dhtml_editor ? "smarteditor2" : "";
|
||||
$html .= "\n<textarea id=\"$id\" name=\"$id\" class=\"$smarteditor_class\" maxlength=\"65536\">$content</textarea>";
|
||||
$html .= "\n<span class=\"sound_only\">웹 에디터 끝</span>";
|
||||
return $html;
|
||||
}
|
||||
|
||||
|
||||
// textarea 로 값을 넘긴다. javascript 반드시 필요
|
||||
function get_editor_js($id, $is_dhtml_editor=true)
|
||||
{
|
||||
if ($is_dhtml_editor) {
|
||||
return "var {$id}_editor_data = oEditors.getById['{$id}'].getIR();\noEditors.getById['{$id}'].exec('UPDATE_CONTENTS_FIELD', []);\n";
|
||||
} else {
|
||||
return "var {$id}_editor = document.getElementById('{$id}');\n";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// textarea 의 값이 비어 있는지 검사
|
||||
function chk_editor_js($id, $is_dhtml_editor=true)
|
||||
{
|
||||
if ($is_dhtml_editor) {
|
||||
return "if (!{$id}_editor_data || {$id}_editor_data == ' ' || {$id}_editor_data == '<p> </p>' || {$id}_editor_data == '<p><br></p>' || {$id}_editor_data == '<p></p>') { alert(\"내용을 입력해 주십시오.\"); oEditors.getById['{$id}'].exec('FOCUS'); return false; }\n";
|
||||
} else {
|
||||
return "if (!{$id}_editor.value) { alert(\"내용을 입력해 주십시오.\"); {$id}_editor.focus(); return false; }\n";
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
After Width: | Height: | Size: 115 B |
|
After Width: | Height: | Size: 526 B |
|
After Width: | Height: | Size: 331 B |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 159 B |
|
After Width: | Height: | Size: 2.3 KiB |
|
After Width: | Height: | Size: 103 B |
|
After Width: | Height: | Size: 43 B |
|
After Width: | Height: | Size: 56 B |
|
After Width: | Height: | Size: 941 B |
|
After Width: | Height: | Size: 1.1 KiB |
|
After Width: | Height: | Size: 104 B |
|
After Width: | Height: | Size: 139 B |
|
After Width: | Height: | Size: 155 B |
|
After Width: | Height: | Size: 270 B |
|
After Width: | Height: | Size: 4.5 KiB |
|
After Width: | Height: | Size: 1.4 MiB |
|
After Width: | Height: | Size: 34 KiB |
|
After Width: | Height: | Size: 11 KiB |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 718 B |
|
After Width: | Height: | Size: 553 B |
|
After Width: | Height: | Size: 553 B |
|
After Width: | Height: | Size: 157 B |
|
After Width: | Height: | Size: 506 B |
|
After Width: | Height: | Size: 7.1 KiB |
@@ -0,0 +1,134 @@
|
||||
if(typeof window.nhn=='undefined') window.nhn = {};
|
||||
if (!nhn.husky) nhn.husky = {};
|
||||
|
||||
/**
|
||||
* @fileOverview This file contains application creation helper function, which would load up an HTML(Skin) file and then execute a specified create function.
|
||||
* @name HuskyEZCreator.js
|
||||
*/
|
||||
nhn.husky.EZCreator = new (function(){
|
||||
this.nBlockerCount = 0;
|
||||
|
||||
this.createInIFrame = function(htOptions){
|
||||
if(arguments.length == 1){
|
||||
var oAppRef = htOptions.oAppRef;
|
||||
var elPlaceHolder = htOptions.elPlaceHolder;
|
||||
var sSkinURI = htOptions.sSkinURI;
|
||||
var fCreator = htOptions.fCreator;
|
||||
var fOnAppLoad = htOptions.fOnAppLoad;
|
||||
var bUseBlocker = htOptions.bUseBlocker;
|
||||
var htParams = htOptions.htParams || null;
|
||||
}else{
|
||||
// for backward compatibility only
|
||||
var oAppRef = arguments[0];
|
||||
var elPlaceHolder = arguments[1];
|
||||
var sSkinURI = arguments[2];
|
||||
var fCreator = arguments[3];
|
||||
var fOnAppLoad = arguments[4];
|
||||
var bUseBlocker = arguments[5];
|
||||
var htParams = arguments[6];
|
||||
}
|
||||
|
||||
if(bUseBlocker) nhn.husky.EZCreator.showBlocker();
|
||||
|
||||
var attachEvent = function(elNode, sEvent, fHandler){
|
||||
if(elNode.addEventListener){
|
||||
elNode.addEventListener(sEvent, fHandler, false);
|
||||
}else{
|
||||
elNode.attachEvent("on"+sEvent, fHandler);
|
||||
}
|
||||
}
|
||||
|
||||
if(!elPlaceHolder){
|
||||
alert("Placeholder is required!");
|
||||
return;
|
||||
}
|
||||
|
||||
if(typeof(elPlaceHolder) != "object")
|
||||
elPlaceHolder = document.getElementById(elPlaceHolder);
|
||||
|
||||
var elIFrame, nEditorWidth, nEditorHeight;
|
||||
|
||||
|
||||
try{
|
||||
elIFrame = document.createElement("<IFRAME frameborder=0 scrolling=no>");
|
||||
}catch(e){
|
||||
elIFrame = document.createElement("IFRAME");
|
||||
elIFrame.setAttribute("frameborder", "0");
|
||||
elIFrame.setAttribute("scrolling", "no");
|
||||
}
|
||||
|
||||
elIFrame.style.width = "1px";
|
||||
elIFrame.style.height = "1px";
|
||||
elPlaceHolder.parentNode.insertBefore(elIFrame, elPlaceHolder.nextSibling);
|
||||
|
||||
attachEvent(elIFrame, "load", function(){
|
||||
fCreator = elIFrame.contentWindow[fCreator] || elIFrame.contentWindow.createSEditor2;
|
||||
|
||||
// top.document.title = ((new Date())-window.STime);
|
||||
// window.STime = new Date();
|
||||
|
||||
try{
|
||||
|
||||
nEditorWidth = elIFrame.contentWindow.document.body.scrollWidth || "500px";
|
||||
nEditorHeight = elIFrame.contentWindow.document.body.scrollHeight + 12;
|
||||
elIFrame.style.width = "100%";
|
||||
elIFrame.style.height = nEditorHeight+ "px";
|
||||
elIFrame.contentWindow.document.body.style.margin = "0";
|
||||
}catch(e){
|
||||
nhn.husky.EZCreator.hideBlocker(true);
|
||||
elIFrame.style.border = "5px solid red";
|
||||
elIFrame.style.width = "500px";
|
||||
elIFrame.style.height = "500px";
|
||||
alert("Failed to access "+sSkinURI);
|
||||
return;
|
||||
}
|
||||
|
||||
var oApp = fCreator(elPlaceHolder, htParams); // oEditor
|
||||
|
||||
|
||||
oApp.elPlaceHolder = elPlaceHolder;
|
||||
|
||||
oAppRef[oAppRef.length] = oApp;
|
||||
if(!oAppRef.getById) oAppRef.getById = {};
|
||||
|
||||
if(elPlaceHolder.id) oAppRef.getById[elPlaceHolder.id] = oApp;
|
||||
|
||||
oApp.run({fnOnAppReady:fOnAppLoad});
|
||||
|
||||
// top.document.title += ", "+((new Date())-window.STime);
|
||||
nhn.husky.EZCreator.hideBlocker();
|
||||
});
|
||||
// window.STime = new Date();
|
||||
elIFrame.src = sSkinURI;
|
||||
this.elIFrame = elIFrame;
|
||||
};
|
||||
|
||||
this.showBlocker = function(){
|
||||
if(this.nBlockerCount<1){
|
||||
var elBlocker = document.createElement("DIV");
|
||||
elBlocker.style.position = "absolute";
|
||||
elBlocker.style.top = 0;
|
||||
elBlocker.style.left = 0;
|
||||
elBlocker.style.backgroundColor = "#FFFFFF";
|
||||
elBlocker.style.width = "100%";
|
||||
|
||||
document.body.appendChild(elBlocker);
|
||||
|
||||
nhn.husky.EZCreator.elBlocker = elBlocker;
|
||||
}
|
||||
|
||||
nhn.husky.EZCreator.elBlocker.style.height = Math.max(document.body.scrollHeight, document.body.clientHeight)+"px";
|
||||
|
||||
this.nBlockerCount++;
|
||||
};
|
||||
|
||||
this.hideBlocker = function(bForce){
|
||||
if(!bForce){
|
||||
if(--this.nBlockerCount > 0) return;
|
||||
}
|
||||
|
||||
this.nBlockerCount = 0;
|
||||
|
||||
if(nhn.husky.EZCreator.elBlocker) nhn.husky.EZCreator.elBlocker.style.display = "none";
|
||||
}
|
||||
})();
|
||||
@@ -0,0 +1,52 @@
|
||||
/*
|
||||
* Smart Editor 2 Configuration : This setting must be changed by service
|
||||
*/
|
||||
window.nhn = window.nhn || {};
|
||||
nhn.husky = nhn.husky || {};
|
||||
nhn.husky.SE2M_Configuration = nhn.husky.SE2M_Configuration || {};
|
||||
|
||||
nhn.husky.SE2M_Configuration.Quote = {
|
||||
sImageBaseURL : 'http://static.se2.naver.com/static/img'
|
||||
};
|
||||
|
||||
nhn.husky.SE2M_Configuration.CustomObject = {
|
||||
sVersion : 1,
|
||||
sClassName : '__se_object',
|
||||
sValueName : 'jsonvalue',
|
||||
sTagIdPrefix : 'se_object_',
|
||||
sTailComment : '<!--__se_object_end -->',
|
||||
sBlankTemplateURL : nhn.husky.SE2M_Configuration.LinkageDomain.sCommonStatic + '/static/db_attach/iframe_template_for_se1_obj.html',
|
||||
sAttributeOfEmpty : 's_isempty="true"',
|
||||
sAttributeOfOldDB : 's_olddb="true"',
|
||||
sBlock : '<div class="_block" style="position:absolute;z-index:10000;background-color:#fff;"></div>',
|
||||
sBlockTemplate : '<div[\\s\\S]*?class=[\'"]?_block[\'"]?[\\s\\S]*?</div>',
|
||||
sHighlight : '<div class="_highlight" style="position:absolute;width:58px;height:16px;line-height:0;z-index:9999"><img src="' + nhn.husky.SE2M_Configuration.LinkageDomain.sCommonStatic + '/static/img/pencil2.png" alt="" width="58" height="16" style="vertical-align:top"></div>',
|
||||
sHighlightTemplate : '<div[\\s\\S]*?class=[\'"]?_highlight[\'"]?[\\s\\S]*?</div>',
|
||||
sHtmlTemplateStartTag : '<!-- se_object_template_start -->',
|
||||
sHtmlTemplateEndTag : '<!-- se_object_template_end -->',
|
||||
sHtmlFilterTag : '{=sType}_{=sSubType}_{=nSeq}',
|
||||
sTplHtmlFilterTag : '<!--{=sType}_{=sSubType}_(\\d+)-->',
|
||||
sImgComServerPath : nhn.husky.SE2M_Configuration.LinkageDomain.sCommonStatic + '/static/img/reviewitem',
|
||||
nMaxWidth : 548
|
||||
};
|
||||
|
||||
nhn.husky.SE2M_Configuration.SE2M_ReEditAction = {
|
||||
bUsed : true,
|
||||
nSecDisplayDulationReEditMsg : 3,
|
||||
aReEditGuideMsg : [
|
||||
'이미지 파일은 1회 클릭 시 크기 조절, 더블클릭 시 재편집이 가능합니다.',
|
||||
'첨부한 파일을 더블클릭 시 재편집이 가능합니다.',
|
||||
'첨부한 글양식 테이블을 드래그시 테이블 재편집이 가능합니다.',
|
||||
'첨부한 표를 드래그 시 표 재편집이 가능합니다.'
|
||||
]
|
||||
};
|
||||
|
||||
nhn.husky.SE2M_Configuration.SE2M_ColorPalette = {
|
||||
bUseRecentColor : false
|
||||
};
|
||||
|
||||
nhn.husky.SE2M_Configuration.QuickEditor = {
|
||||
common : {
|
||||
bUseConfig : false
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,71 @@
|
||||
/*
|
||||
* Smart Editor 2 Configuration : This setting must be changed by service
|
||||
*/
|
||||
window.nhn = window.nhn || {};
|
||||
nhn.husky = nhn.husky || {};
|
||||
nhn.husky.SE2M_Configuration = nhn.husky.SE2M_Configuration || {};
|
||||
|
||||
/**
|
||||
* 스마트에디터2에서 접근하는 JS, IMG 디렉토리
|
||||
*/
|
||||
nhn.husky.SE2M_Configuration.Editor = {
|
||||
sJsBaseURL : './js_src',
|
||||
sImageBaseURL : './img/'
|
||||
};
|
||||
|
||||
/**
|
||||
* JS LazyLoad를 위한 경로
|
||||
*/
|
||||
nhn.husky.SE2M_Configuration.LazyLoad = {
|
||||
sJsBaseURI : "js_lazyload"
|
||||
};
|
||||
|
||||
/**
|
||||
* CSS LazyLoad를 위한 경로
|
||||
*/
|
||||
nhn.husky.SE2M_Configuration.SE2B_CSSLoader = {
|
||||
sCSSBaseURI : "css"
|
||||
};
|
||||
|
||||
/**
|
||||
* 편집영역 설정
|
||||
*/
|
||||
nhn.husky.SE2M_Configuration.SE_EditingAreaManager = {
|
||||
sCSSBaseURI : "css",
|
||||
sBlankPageURL : "smart_editor2_inputarea.html",
|
||||
sBlankPageURL_EmulateIE7 : "smart_editor2_inputarea_ie8.html",
|
||||
aAddtionalEmulateIE7 : [] // IE8 default 사용, IE9 ~ 선택적 사용
|
||||
};
|
||||
|
||||
/**
|
||||
* 스마트에디터2에서 사용하는 도메인 정보
|
||||
* http://wiki.nhncorp.com/pages/viewpage.action?pageId=74253685
|
||||
*/
|
||||
nhn.husky.SE2M_Configuration.LinkageDomain = {
|
||||
sCommonAPI : 'http://api.se2.naver.com',
|
||||
sCommonStatic : 'http://static.se2.naver.com',
|
||||
sCommonImage : 'http://images.se2.naver.com'
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* [웹접근성]
|
||||
* 단축키 ALT+, ALT+. 을 이용하여 스마트에디터 영역의 이전/이후 요소로 이동할 수 있다.
|
||||
* sBeforeElementId : 스마트에디터 영역 이전 요소의 id
|
||||
* sNextElementId : 스마트에디터 영역 이후 요소의 id
|
||||
*
|
||||
* 스마트에디터 영역 이외의 제목 영역 (예:스마트에디터가 적용된 블로그 쓰기 페이지에서의 제목 영역) 에 해당하는 엘리먼트에서 Tab키를 누르면 에디팅 영역으로 포커스를 이동시킬 수 있다.
|
||||
* sTitleElementId : 제목에 해당하는 input 요소의 id.
|
||||
*/
|
||||
nhn.husky.SE2M_Configuration.SE2M_Accessibility = {
|
||||
sBeforeElementId : '',
|
||||
sNextElementId : '',
|
||||
sTitleElementId : ''
|
||||
};
|
||||
|
||||
/**
|
||||
* 링크 기능 옵션
|
||||
*/
|
||||
nhn.husky.SE2M_Configuration.SE2M_Hyperlink = {
|
||||
bAutolink : true // 자동링크기능 사용여부(기본값:true)
|
||||
};
|
||||
@@ -0,0 +1,91 @@
|
||||
function createSEditor2(elIRField, htParams, elSeAppContainer){
|
||||
if(!window.$Jindo){
|
||||
parent.document.body.innerHTML="진도 프레임웍이 필요합니다.<br>\n<a href='http://dev.naver.com/projects/jindo/download'>http://dev.naver.com/projects/jindo/download</a>에서 Jindo 1.5.3 버전의 jindo.min.js를 다운로드 받아 /js 폴더에 복사 해 주세요.\n(아직 Jindo 2 는 지원하지 않습니다.)";
|
||||
return;
|
||||
}
|
||||
|
||||
var elAppContainer = (elSeAppContainer || jindo.$("smart_editor2"));
|
||||
var elEditingArea = jindo.$$.getSingle("DIV.husky_seditor_editing_area_container", elAppContainer);
|
||||
var oWYSIWYGIFrame = jindo.$$.getSingle("IFRAME.se2_input_wysiwyg", elEditingArea);
|
||||
var oIRTextarea = elIRField?elIRField:jindo.$$.getSingle("TEXTAREA.blind", elEditingArea);
|
||||
var oHTMLSrc = jindo.$$.getSingle("TEXTAREA.se2_input_htmlsrc", elEditingArea);
|
||||
var oTextArea = jindo.$$.getSingle("TEXTAREA.se2_input_text", elEditingArea);
|
||||
var sEditorMode = "open";
|
||||
|
||||
if(!htParams){
|
||||
htParams = {};
|
||||
htParams.fOnBeforeUnload = null;
|
||||
}
|
||||
htParams.elAppContainer = elAppContainer; // 에디터 UI 최상위 element 셋팅
|
||||
htParams.oNavigator = jindo.$Agent().navigator(); // navigator 객체 셋팅
|
||||
|
||||
var oEditor = new nhn.husky.HuskyCore(htParams);
|
||||
oEditor.registerPlugin(new nhn.husky.CorePlugin(htParams?htParams.fOnAppLoad:null));
|
||||
oEditor.registerPlugin(new nhn.husky.StringConverterManager());
|
||||
|
||||
var htDimension = {
|
||||
nMinHeight:320,
|
||||
nMinWidth:parseInt(elIRField.style.minWidth, 10)||570,
|
||||
nHeight:elIRField.style.height||elIRField.offsetHeight,
|
||||
nWidth:elIRField.style.width||elIRField.offsetWidth
|
||||
};
|
||||
|
||||
var htConversionMode = {
|
||||
bUseVerticalResizer : htParams.bUseVerticalResizer,
|
||||
bUseModeChanger : htParams.bUseModeChanger
|
||||
};
|
||||
|
||||
var aAdditionalFontList = htParams.aAdditionalFontList;
|
||||
|
||||
oEditor.registerPlugin(new nhn.husky.SE_EditingAreaManager("WYSIWYG", oIRTextarea, htDimension, htParams.fOnBeforeUnload, elAppContainer));
|
||||
oEditor.registerPlugin(new nhn.husky.SE_EditingArea_WYSIWYG(oWYSIWYGIFrame)); // Tab Editor 모드
|
||||
oEditor.registerPlugin(new nhn.husky.SE_EditingArea_HTMLSrc(oHTMLSrc)); // Tab HTML 모드
|
||||
oEditor.registerPlugin(new nhn.husky.SE_EditingArea_TEXT(oTextArea)); // Tab Text 모드
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_EditingModeChanger(elAppContainer, htConversionMode)); // 모드간 변경(Editor, HTML, Text)
|
||||
oEditor.registerPlugin(new nhn.husky.SE_PasteHandler()); // WYSIWYG Paste Handler
|
||||
|
||||
oEditor.registerPlugin(new nhn.husky.HuskyRangeManager(oWYSIWYGIFrame));
|
||||
oEditor.registerPlugin(new nhn.husky.Utils());
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_UtilPlugin());
|
||||
oEditor.registerPlugin(new nhn.husky.SE_WYSIWYGStyler());
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_Toolbar(elAppContainer));
|
||||
|
||||
oEditor.registerPlugin(new nhn.husky.Hotkey()); // 단축키
|
||||
oEditor.registerPlugin(new nhn.husky.SE_EditingAreaVerticalResizer(elAppContainer, htConversionMode)); // 편집영역 리사이즈
|
||||
oEditor.registerPlugin(new nhn.husky.DialogLayerManager());
|
||||
oEditor.registerPlugin(new nhn.husky.ActiveLayerManager());
|
||||
oEditor.registerPlugin(new nhn.husky.SE_WYSIWYGStyleGetter()); // 커서 위치 스타일 정보 가져오기
|
||||
|
||||
oEditor.registerPlugin(new nhn.husky.SE2B_Customize_ToolBar(elAppContainer)); // 상단 툴바 (Basic)
|
||||
oEditor.registerPlugin(new nhn.husky.SE_WYSIWYGEnterKey("P")); // 엔터 시 처리, 현재는 P로 처리
|
||||
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_ColorPalette(elAppContainer)); // 색상 팔레트
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_FontColor(elAppContainer)); // 글자색
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_BGColor(elAppContainer)); // 글자배경색
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_FontNameWithLayerUI(elAppContainer, aAdditionalFontList)); // 글꼴종류
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_FontSizeWithLayerUI(elAppContainer)); // 글꼴크기
|
||||
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_LineStyler());
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_ExecCommand(oWYSIWYGIFrame));
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_LineHeightWithLayerUI(elAppContainer)); // 줄간격
|
||||
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_Quote(elAppContainer)); // 인용구
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_Hyperlink(elAppContainer)); // 링크
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_SCharacter(elAppContainer)); // 특수문자
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_FindReplacePlugin(elAppContainer)); // 찾기/바꾸기
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_TableCreator(elAppContainer)); // 테이블 생성
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_TableEditor(elAppContainer)); // 테이블 편집
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_TableBlockStyler(elAppContainer)); // 테이블 스타일
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_AttachQuickPhoto(elAppContainer)); // 사진
|
||||
|
||||
oEditor.registerPlugin(new nhn.husky.MessageManager(oMessageMap));
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_QuickEditor_Common(elAppContainer)); // 퀵에디터 공통(표, 이미지)
|
||||
|
||||
oEditor.registerPlugin(new nhn.husky.SE2B_CSSLoader()); // CSS lazy load
|
||||
oEditor.registerPlugin(new nhn.husky.SE_OuterIFrameControl(elAppContainer, 100));
|
||||
|
||||
oEditor.registerPlugin(new nhn.husky.SE_ToolbarToggler(elAppContainer, htParams.bUseToolbar));
|
||||
oEditor.registerPlugin(new nhn.husky.SE2M_Accessibility(elAppContainer)); // 에디터내의 웹접근성 관련 기능모음 플러그인
|
||||
|
||||
return oEditor;
|
||||
}
|
||||
@@ -0,0 +1,105 @@
|
||||
/**
|
||||
* @use 간단 포토 업로드용으로 제작되었습니다.
|
||||
* @author cielo
|
||||
* @See nhn.husky.SE2M_Configuration
|
||||
* @ 팝업 마크업은 SimplePhotoUpload.html과 SimplePhotoUpload_html5.html이 있습니다.
|
||||
*/
|
||||
|
||||
nhn.husky.SE2M_AttachQuickPhoto = jindo.$Class({
|
||||
name : "SE2M_AttachQuickPhoto",
|
||||
|
||||
$init : function(){},
|
||||
|
||||
$ON_MSG_APP_READY : function(){
|
||||
this.oApp.exec("REGISTER_UI_EVENT", ["photo_attach", "click", "ATTACHPHOTO_OPEN_WINDOW"]);
|
||||
},
|
||||
|
||||
$LOCAL_BEFORE_FIRST : function(sMsg){
|
||||
if(!!this.oPopupMgr){ return; }
|
||||
// Popup Manager에서 사용할 param
|
||||
this.htPopupOption = {
|
||||
oApp : this.oApp,
|
||||
sName : this.name,
|
||||
bScroll : false,
|
||||
sProperties : "",
|
||||
sUrl : ""
|
||||
};
|
||||
this.oPopupMgr = nhn.husky.PopUpManager.getInstance(this.oApp);
|
||||
},
|
||||
|
||||
/**
|
||||
* 포토 웹탑 오픈
|
||||
*/
|
||||
$ON_ATTACHPHOTO_OPEN_WINDOW : function(){
|
||||
this.htPopupOption.sUrl = this.makePopupURL();
|
||||
this.htPopupOption.sProperties = "left=0,top=0,width=640,height=459,scrollbars=yes,location=no,status=0,resizable=no";
|
||||
|
||||
this.oPopupWindow = this.oPopupMgr.openWindow(this.htPopupOption);
|
||||
|
||||
// 처음 로딩하고 IE에서 커서가 전혀 없는 경우
|
||||
// 복수 업로드시에 순서가 바뀜
|
||||
this.oApp.exec('FOCUS');
|
||||
return (!!this.oPopupWindow ? true : false);
|
||||
},
|
||||
|
||||
/**
|
||||
* 서비스별로 팝업에 parameter를 추가하여 URL을 생성하는 함수
|
||||
* nhn.husky.SE2M_AttachQuickPhoto.prototype.makePopupURL로 덮어써서 사용하시면 됨.
|
||||
*/
|
||||
makePopupURL : function(){
|
||||
//var sPopupUrl = "./photo_uploader/popup/photo_uploader.html";
|
||||
var sPopupUrl = "./photo_uploader/popup/index.html";
|
||||
return sPopupUrl;
|
||||
},
|
||||
|
||||
/**
|
||||
* 팝업에서 호출되는 메세지.
|
||||
*/
|
||||
$ON_SET_PHOTO : function(aPhotoData){
|
||||
var sContents,
|
||||
aPhotoInfo,
|
||||
htData;
|
||||
|
||||
if( !aPhotoData ){
|
||||
return;
|
||||
}
|
||||
|
||||
try{
|
||||
sContents = "";
|
||||
for(var i = 0; i <aPhotoData.length; i++){
|
||||
htData = aPhotoData[i];
|
||||
|
||||
if(!htData.sAlign){
|
||||
htData.sAlign = "";
|
||||
}
|
||||
|
||||
aPhotoInfo = {
|
||||
sName : htData.sFileName || "",
|
||||
sOriginalImageURL : htData.sFileURL,
|
||||
bNewLine : htData.bNewLine || false
|
||||
};
|
||||
|
||||
sContents += this._getPhotoTag(aPhotoInfo);
|
||||
}
|
||||
|
||||
this.oApp.exec("PASTE_HTML", [sContents]); // 위즐 첨부 파일 부분 확인
|
||||
}catch(e){
|
||||
// upload시 error발생에 대해서 skip함
|
||||
return false;
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* @use 일반 포토 tag 생성
|
||||
*/
|
||||
_getPhotoTag : function(htPhotoInfo){
|
||||
// id와 class는 썸네일과 연관이 많습니다. 수정시 썸네일 영역도 Test
|
||||
var sTag = '<img src="{=sOriginalImageURL}" title="{=sName}" >';
|
||||
if(htPhotoInfo.bNewLine){
|
||||
sTag += '<br style="clear:both;">';
|
||||
}
|
||||
sTag = jindo.$Template(sTag).process(htPhotoInfo);
|
||||
|
||||
return sTag;
|
||||
}
|
||||
});
|
||||
@@ -0,0 +1,681 @@
|
||||
//변수 선언 및 초기화
|
||||
var nImageInfoCnt = 0;
|
||||
var htImageInfo = []; //image file정보 저장
|
||||
var aResult = [];
|
||||
|
||||
var rFilter = /^(image\/bmp|image\/gif|image\/jpg|image\/jpeg|image\/png)$/i;
|
||||
var rFilter2 = /^(bmp|gif|jpg|jpeg|png)$/i;
|
||||
var nTotalSize = 0;
|
||||
var nMaxImageSize = 10*1024*1024;
|
||||
var nMaxTotalImageSize = 50*1024*1024;
|
||||
var nMaxImageCount = 10;
|
||||
var nImageFileCount = 0;
|
||||
var bSupportDragAndDropAPI = false;
|
||||
var oFileUploader;
|
||||
var bAttachEvent = false;
|
||||
|
||||
//마크업에 따른 할당
|
||||
var elContent= $("pop_content");
|
||||
var elDropArea = jindo.$$.getSingle(".drag_area",elContent);
|
||||
var elDropAreaUL = jindo.$$.getSingle(".lst_type",elContent);
|
||||
var elCountTxtTxt = jindo.$$.getSingle("#imageCountTxt",elContent);
|
||||
var elTotalSizeTxt = jindo.$$.getSingle("#totalSizeTxt",elContent);
|
||||
var elTextGuide = $("guide_text");
|
||||
var welUploadInputBox = $Element("uploadInputBox");
|
||||
var oNavigator = jindo.$Agent().navigator();
|
||||
|
||||
//마크업-공통
|
||||
var welBtnConfirm = $Element("btn_confirm"); //확인 버튼
|
||||
var welBtnCancel= $Element("btn_cancel"); //취소 버튼
|
||||
|
||||
//진도로 랩핑된 element
|
||||
var welTextGuide = $Element(elTextGuide);
|
||||
var welDropArea = $Element(elDropArea);
|
||||
var welDropAreaUL = $Element(elDropAreaUL);
|
||||
var fnUploadImage = null;
|
||||
|
||||
//File API 지원 여부로 결정
|
||||
function checkDragAndDropAPI(){
|
||||
try{
|
||||
if( !oNavigator.ie ){
|
||||
if(!!oNavigator.safari && oNavigator.version <= 5){
|
||||
bSupportDragAndDropAPI = false;
|
||||
}else{
|
||||
bSupportDragAndDropAPI = true;
|
||||
}
|
||||
} else {
|
||||
bSupportDragAndDropAPI = false;
|
||||
}
|
||||
}catch(e){
|
||||
bSupportDragAndDropAPI = false;
|
||||
}
|
||||
}
|
||||
|
||||
//--------------- html5 미지원 브라우저에서 (IE9 이하) ---------------
|
||||
/**
|
||||
* 이미지를 첨부 후 활성화된 버튼 상태
|
||||
*/
|
||||
function goStartMode(){
|
||||
var sSrc = welBtnConfirm.attr("src")|| "";
|
||||
if(sSrc.indexOf("btn_confirm2.png") < 0 ){
|
||||
welBtnConfirm.attr("src","../../img/photoQuickPopup/btn_confirm2.png");
|
||||
fnUploadImage.attach(welBtnConfirm.$value(), "click");
|
||||
}
|
||||
}
|
||||
/**
|
||||
* 이미지를 첨부 전 비활성화된 버튼 상태
|
||||
* @return
|
||||
*/
|
||||
function goReadyMode(){
|
||||
var sSrc = welBtnConfirm.attr("src")|| "";
|
||||
if(sSrc.indexOf("btn_confirm2.png") >= 0 ){
|
||||
fnUploadImage.detach(welBtnConfirm.$value(), "click");
|
||||
welBtnConfirm.attr("src","../../img/photoQuickPopup/btn_confirm.png");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 일반 업로드
|
||||
* @desc oFileUploader의 upload함수를 호출함.
|
||||
*/
|
||||
function generalUpload(){
|
||||
oFileUploader.upload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 이미지 첨부 전 안내 텍스트가 나오는 배경으로 '설정'하는 함수.
|
||||
* @return
|
||||
*/
|
||||
function readyModeBG (){
|
||||
var sClass = welTextGuide.className();
|
||||
if(sClass.indexOf('nobg') >= 0){
|
||||
welTextGuide.removeClass('nobg');
|
||||
welTextGuide.className('bg');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 이미지 첨부 전 안내 텍스트가 나오는 배경을 '제거'하는 함수.
|
||||
* @return
|
||||
*/
|
||||
function startModeBG (){
|
||||
var sClass = welTextGuide.className();
|
||||
if(sClass.indexOf('nobg') < 0){
|
||||
welTextGuide.removeClass('bg');
|
||||
welTextGuide.className('nobg');
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------- html5 지원되는 브라우저에서 사용하는 함수 --------------------------
|
||||
/**
|
||||
* 팝업에 노출될 업로드 예정 사진의 수.
|
||||
* @param {Object} nCount 현재 업로드 예정인 사진 장수
|
||||
* @param {Object} nVariable 삭제되는 수
|
||||
*/
|
||||
function updateViewCount (nCount, nVariable){
|
||||
var nCnt = nCount + nVariable;
|
||||
elCountTxtTxt.innerHTML = nCnt +"장";
|
||||
nImageFileCount = nCnt;
|
||||
return nCnt;
|
||||
}
|
||||
|
||||
/**
|
||||
* 팝업에 노출될 업로드될 사진 총 용량
|
||||
*/
|
||||
function updateViewTotalSize(){
|
||||
var nViewTotalSize = Number(parseInt((nTotalSize || 0), 10) / (1024*1024));
|
||||
elTotalSizeTxt.innerHTML = nViewTotalSize.toFixed(2) +"MB";
|
||||
}
|
||||
|
||||
/**
|
||||
* 이미지 전체 용량 재계산.
|
||||
* @param {Object} sParentId
|
||||
*/
|
||||
function refreshTotalImageSize(sParentId){
|
||||
var nDelImgSize = htImageInfo[sParentId].size;
|
||||
if(nTotalSize - nDelImgSize > -1 ){
|
||||
nTotalSize = nTotalSize - nDelImgSize;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* hash table에서 이미지 정보 초기화.
|
||||
* @param {Object} sParentId
|
||||
*/
|
||||
function removeImageInfo (sParentId){
|
||||
//삭제된 이미지의 공간을 초기화 한다.
|
||||
htImageInfo[sParentId] = null;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* byte로 받은 이미지 용량을 화면에 표시를 위해 포맷팅
|
||||
* @param {Object} nByte
|
||||
*/
|
||||
function setUnitString (nByte) {
|
||||
var nImageSize;
|
||||
var sUnit;
|
||||
|
||||
if(nByte < 0 ){
|
||||
nByte = 0;
|
||||
}
|
||||
|
||||
if( nByte < 1024) {
|
||||
nImageSize = Number(nByte);
|
||||
sUnit = 'B';
|
||||
return nImageSize + sUnit;
|
||||
} else if( nByte > (1024*1024)) {
|
||||
nImageSize = Number(parseInt((nByte || 0), 10) / (1024*1024));
|
||||
sUnit = 'MB';
|
||||
return nImageSize.toFixed(2) + sUnit;
|
||||
} else {
|
||||
nImageSize = Number(parseInt((nByte || 0), 10) / 1024);
|
||||
sUnit = 'KB';
|
||||
return nImageSize.toFixed(0) + sUnit;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 화면 목록에 적당하게 이름을 잘라서 표시.
|
||||
* @param {Object} sName 파일명
|
||||
* @param {Object} nMaxLng 최대 길이
|
||||
*/
|
||||
function cuttingNameByLength (sName, nMaxLng) {
|
||||
var sTemp, nIndex;
|
||||
if(sName.length > nMaxLng){
|
||||
nIndex = sName.indexOf(".");
|
||||
sTemp = sName.substring(0,nMaxLng) + "..." + sName.substring(nIndex,sName.length) ;
|
||||
} else {
|
||||
sTemp = sName;
|
||||
}
|
||||
return sTemp;
|
||||
}
|
||||
|
||||
/**
|
||||
* Total Image Size를 체크해서 추가로 이미지를 넣을지 말지를 결정함.
|
||||
* @param {Object} nByte
|
||||
*/
|
||||
function checkTotalImageSize(nByte){
|
||||
if( nTotalSize + nByte < nMaxTotalImageSize){
|
||||
nTotalSize = nTotalSize + nByte;
|
||||
return false;
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
// 이벤트 핸들러 할당
|
||||
function dragEnter(ev) {
|
||||
ev.stopPropagation();
|
||||
ev.preventDefault();
|
||||
}
|
||||
|
||||
function dragExit(ev) {
|
||||
ev.stopPropagation();
|
||||
ev.preventDefault();
|
||||
}
|
||||
|
||||
function dragOver(ev) {
|
||||
ev.stopPropagation();
|
||||
ev.preventDefault();
|
||||
}
|
||||
|
||||
/**
|
||||
* 드랍 영역에 사진을 떨구는 순간 발생하는 이벤트
|
||||
* @param {Object} ev
|
||||
*/
|
||||
function drop(ev) {
|
||||
ev.stopPropagation();
|
||||
ev.preventDefault();
|
||||
|
||||
if (nImageFileCount >= 10){
|
||||
alert("최대 10장까지만 등록할 수 있습니다.");
|
||||
return;
|
||||
}
|
||||
|
||||
if(typeof ev.dataTransfer.files == 'undefined'){
|
||||
alert("HTML5를 지원하지 않는 브라우저입니다.");
|
||||
}else{
|
||||
//변수 선언
|
||||
var wel,
|
||||
files,
|
||||
nCount,
|
||||
sListTag = '';
|
||||
|
||||
//초기화
|
||||
files = ev.dataTransfer.files;
|
||||
nCount = files.length;
|
||||
|
||||
if (!!files && nCount === 0){
|
||||
//파일이 아닌, 웹페이지에서 이미지를 드래서 놓는 경우.
|
||||
alert("정상적인 첨부방식이 아닙니다.");
|
||||
return ;
|
||||
}
|
||||
|
||||
for (var i = 0, j = nImageFileCount ; i < nCount ; i++){
|
||||
if (!rFilter.test(files[i].type)) {
|
||||
alert("이미지파일 (jpg,gif,png,bmp)만 업로드 가능합니다.");
|
||||
} else if(files[i].size > nMaxImageSize){
|
||||
alert("이미지 용량이 10MB를 초과하여 등록할 수 없습니다.");
|
||||
} else {
|
||||
//제한된 수만 업로드 가능.
|
||||
if ( j < nMaxImageCount ){
|
||||
sListTag += addImage(files[i]);
|
||||
|
||||
//다음 사진을위한 셋팅
|
||||
j = j+1;
|
||||
nImageInfoCnt = nImageInfoCnt+1;
|
||||
} else {
|
||||
alert("최대 10장까지만 등록할 수 있습니다.");
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
if(j > 0){
|
||||
//배경 이미지 변경
|
||||
startModeBG();
|
||||
if ( sListTag.length > 1){
|
||||
welDropAreaUL.prependHTML(sListTag);
|
||||
}
|
||||
//이미지 총사이즈 view update
|
||||
updateViewTotalSize();
|
||||
//이미치 총 수 view update
|
||||
nImageFileCount = j;
|
||||
updateViewCount(nImageFileCount, 0);
|
||||
// 저장 버튼 활성화
|
||||
goStartMode();
|
||||
}else{
|
||||
readyModeBG();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 이미지를 추가하기 위해서 file을 저장하고, 목록에 보여주기 위해서 string을 만드는 함수.
|
||||
* @param ofile 한개의 이미지 파일
|
||||
* @return
|
||||
*/
|
||||
function addImage(ofile){
|
||||
//파일 사이즈
|
||||
var ofile = ofile,
|
||||
sFileSize = 0,
|
||||
sFileName = "",
|
||||
sLiTag = "",
|
||||
bExceedLimitTotalSize = false,
|
||||
aFileList = [];
|
||||
|
||||
sFileSize = setUnitString(ofile.size);
|
||||
sFileName = cuttingNameByLength(ofile.name, 15);
|
||||
bExceedLimitTotalSize = checkTotalImageSize(ofile.size);
|
||||
|
||||
if( !!bExceedLimitTotalSize ){
|
||||
alert("전체 이미지 용량이 50MB를 초과하여 등록할 수 없습니다. \n\n (파일명 : "+sFileName+", 사이즈 : "+sFileSize+")");
|
||||
} else {
|
||||
//이미지 정보 저장
|
||||
htImageInfo['img'+nImageInfoCnt] = ofile;
|
||||
|
||||
//List 마크업 생성하기
|
||||
aFileList.push(' <li id="img'+nImageInfoCnt+'" class="imgLi"><span>'+ sFileName +'</span>');
|
||||
aFileList.push(' <em>'+ sFileSize +'</em>');
|
||||
aFileList.push(' <a onclick="delImage(\'img'+nImageInfoCnt+'\')"><img class="del_button" src="../../img/photoQuickPopup/btn_del.png" width="14" height="13" alt="첨부 사진 삭제"></a>');
|
||||
aFileList.push(' </li> ');
|
||||
|
||||
sLiTag = aFileList.join(" ");
|
||||
aFileList = [];
|
||||
}
|
||||
return sLiTag;
|
||||
}
|
||||
|
||||
/**
|
||||
* HTML5 DragAndDrop으로 사진을 추가하고, 확인버튼을 누른 경우에 동작한다.
|
||||
* @return
|
||||
*/
|
||||
function html5Upload() {
|
||||
var tempFile,
|
||||
sUploadURL;
|
||||
|
||||
sUploadURL= 'file_uploader_html5.php'; //upload URL
|
||||
|
||||
//파일을 하나씩 보내고, 결과를 받음.
|
||||
for(var j=0, k=0; j < nImageInfoCnt; j++) {
|
||||
tempFile = htImageInfo['img'+j];
|
||||
try{
|
||||
if(!!tempFile){
|
||||
//Ajax통신하는 부분. 파일과 업로더할 url을 전달한다.
|
||||
callAjaxForHTML5(tempFile,sUploadURL);
|
||||
k += 1;
|
||||
}
|
||||
}catch(e){}
|
||||
tempFile = null;
|
||||
}
|
||||
}
|
||||
|
||||
function callAjaxForHTML5 (tempFile, sUploadURL){
|
||||
var oAjax = jindo.$Ajax(sUploadURL, {
|
||||
type: 'xhr',
|
||||
method : "post",
|
||||
onload : function(res){ // 요청이 완료되면 실행될 콜백 함수
|
||||
var sResString = res._response.responseText;
|
||||
if (res.readyState() == 4) {
|
||||
if(sResString.indexOf("NOTALLOW_") > -1){
|
||||
var sFileName = sResString.replace("NOTALLOW_", "");
|
||||
alert("이미지 파일(jpg,gif,png,bmp)만 업로드 하실 수 있습니다. ("+sFileName+")");
|
||||
}else{
|
||||
//성공 시에 responseText를 가지고 array로 만드는 부분.
|
||||
makeArrayFromString(res._response.responseText);
|
||||
}
|
||||
}
|
||||
},
|
||||
timeout : 3,
|
||||
onerror : jindo.$Fn(onAjaxError, this).bind()
|
||||
});
|
||||
oAjax.header("contentType","multipart/form-data");
|
||||
oAjax.header("file-name",encodeURIComponent(tempFile.name));
|
||||
oAjax.header("file-size",tempFile.size);
|
||||
oAjax.header("file-Type",tempFile.type);
|
||||
oAjax.request(tempFile);
|
||||
}
|
||||
|
||||
function makeArrayFromString(sResString){
|
||||
var aTemp = [],
|
||||
aSubTemp = [],
|
||||
htTemp = {}
|
||||
aResultleng = 0;
|
||||
|
||||
try{
|
||||
if(!sResString || sResString.indexOf("sFileURL") < 0){
|
||||
return ;
|
||||
}
|
||||
aTemp = sResString.split("&");
|
||||
for (var i = 0; i < aTemp.length ; i++){
|
||||
if( !!aTemp[i] && aTemp[i] != "" && aTemp[i].indexOf("=") > 0){
|
||||
aSubTemp = aTemp[i].split("=");
|
||||
htTemp[aSubTemp[0]] = aSubTemp[1];
|
||||
}
|
||||
}
|
||||
}catch(e){}
|
||||
|
||||
aResultleng = aResult.length;
|
||||
aResult[aResultleng] = htTemp;
|
||||
|
||||
if(aResult.length == nImageFileCount){
|
||||
setPhotoToEditor(aResult);
|
||||
aResult = null;
|
||||
window.close();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 사진 삭제 시에 호출되는 함수
|
||||
* @param {Object} sParentId
|
||||
*/
|
||||
function delImage (sParentId){
|
||||
var elLi = jindo.$$.getSingle("#"+sParentId);
|
||||
|
||||
refreshTotalImageSize(sParentId);
|
||||
|
||||
updateViewTotalSize();
|
||||
updateViewCount(nImageFileCount,-1);
|
||||
//사진 file array에서 정보 삭제.
|
||||
removeImageInfo(sParentId);
|
||||
//해당 li삭제
|
||||
$Element(elLi).leave();
|
||||
|
||||
//마지막 이미지인경우.
|
||||
if(nImageFileCount === 0){
|
||||
readyModeBG();
|
||||
//사진 추가 버튼 비활성화
|
||||
goReadyMode();
|
||||
}
|
||||
|
||||
// drop 영역 이벤트 다시 활성화.
|
||||
if(!bAttachEvent){
|
||||
addEvent();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 이벤트 할당
|
||||
*/
|
||||
function addEvent() {
|
||||
bAttachEvent = true;
|
||||
elDropArea.addEventListener("dragenter", dragEnter, false);
|
||||
elDropArea.addEventListener("dragexit", dragExit, false);
|
||||
elDropArea.addEventListener("dragover", dragOver, false);
|
||||
elDropArea.addEventListener("drop", drop, false);
|
||||
}
|
||||
|
||||
function removeEvent(){
|
||||
bAttachEvent = false;
|
||||
elDropArea.removeEventListener("dragenter", dragEnter, false);
|
||||
elDropArea.removeEventListener("dragexit", dragExit, false);
|
||||
elDropArea.removeEventListener("dragover", dragOver, false);
|
||||
elDropArea.removeEventListener("drop", drop, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* Ajax 통신 시 error가 발생할 때 처리하는 함수입니다.
|
||||
* @return
|
||||
*/
|
||||
function onAjaxError (){
|
||||
alert("[가이드]사진 업로더할 서버URL셋팅이 필요합니다.-onAjaxError");
|
||||
}
|
||||
|
||||
/**
|
||||
* 이미지 업로드 시작
|
||||
* 확인 버튼 클릭하면 호출되는 msg
|
||||
*/
|
||||
function uploadImage (e){
|
||||
if(!bSupportDragAndDropAPI){
|
||||
generalUpload();
|
||||
}else{
|
||||
html5Upload();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* jindo에 파일 업로드 사용.(iframe에 Form을 Submit하여 리프레시없이 파일을 업로드하는 컴포넌트)
|
||||
*/
|
||||
function callFileUploader (){
|
||||
oFileUploader = new jindo.FileUploader(jindo.$("uploadInputBox"),{
|
||||
sUrl : location.href.replace(/\/[^\/]*$/, '') + '/file_uploader.php', //샘플 URL입니다.
|
||||
sCallback : location.href.replace(/\/[^\/]*$/, '') + '/callback.html', //업로드 이후에 iframe이 redirect될 콜백페이지의 주소
|
||||
sFiletype : "*.jpg;*.png;*.bmp;*.gif", //허용할 파일의 형식. ex) "*", "*.*", "*.jpg", 구분자(;)
|
||||
sMsgNotAllowedExt : 'JPG, GIF, PNG, BMP 확장자만 가능합니다', //허용할 파일의 형식이 아닌경우에 띄워주는 경고창의 문구
|
||||
bAutoUpload : false, //파일이 선택됨과 동시에 자동으로 업로드를 수행할지 여부 (upload 메소드 수행)
|
||||
bAutoReset : true // 업로드한 직후에 파일폼을 리셋 시킬지 여부 (reset 메소드 수행)
|
||||
}).attach({
|
||||
select : function(oCustomEvent) {
|
||||
//파일 선택이 완료되었을 때 발생
|
||||
// oCustomEvent (이벤트 객체) = {
|
||||
// sValue (String) 선택된 File Input의 값
|
||||
// bAllowed (Boolean) 선택된 파일의 형식이 허용되는 형식인지 여부
|
||||
// sMsgNotAllowedExt (String) 허용되지 않는 파일 형식인 경우 띄워줄 경고메세지
|
||||
// }
|
||||
// 선택된 파일의 형식이 허용되는 경우만 처리
|
||||
if(oCustomEvent.bAllowed === true){
|
||||
goStartMode();
|
||||
}else{
|
||||
goReadyMode();
|
||||
oFileUploader.reset();
|
||||
}
|
||||
// bAllowed 값이 false인 경우 경고문구와 함께 alert 수행
|
||||
// oCustomEvent.stop(); 수행시 bAllowed 가 false이더라도 alert이 수행되지 않음
|
||||
},
|
||||
success : function(oCustomEvent) {
|
||||
// alert("success");
|
||||
// 업로드가 성공적으로 완료되었을 때 발생
|
||||
// oCustomEvent(이벤트 객체) = {
|
||||
// htResult (Object) 서버에서 전달해주는 결과 객체 (서버 설정에 따라 유동적으로 선택가능)
|
||||
// }
|
||||
var aResult = [];
|
||||
aResult[0] = oCustomEvent.htResult;
|
||||
setPhotoToEditor(aResult);
|
||||
//버튼 비활성화
|
||||
goReadyMode();
|
||||
oFileUploader.reset();
|
||||
window.close();
|
||||
},
|
||||
error : function(oCustomEvent) {
|
||||
//업로드가 실패했을 때 발생
|
||||
//oCustomEvent(이벤트 객체) = {
|
||||
// htResult : { (Object) 서버에서 전달해주는 결과 객체. 에러발생시 errstr 프로퍼티를 반드시 포함하도록 서버 응답을 설정하여야한다.
|
||||
// errstr : (String) 에러메시지
|
||||
// }
|
||||
//}
|
||||
//var wel = jindo.$Element("info");
|
||||
//wel.html(oCustomEvent.htResult.errstr);
|
||||
alert(oCustomEvent.htResult.errstr);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 페이지 닫기 버튼 클릭
|
||||
*/
|
||||
function closeWindow(){
|
||||
if(bSupportDragAndDropAPI){
|
||||
removeEvent();
|
||||
}
|
||||
window.close();
|
||||
}
|
||||
|
||||
window.onload = function(){
|
||||
checkDragAndDropAPI();
|
||||
|
||||
if(bSupportDragAndDropAPI){
|
||||
$Element("pop_container2").hide();
|
||||
$Element("pop_container").show();
|
||||
|
||||
welTextGuide.removeClass("nobg");
|
||||
welTextGuide.className("bg");
|
||||
|
||||
addEvent();
|
||||
} else {
|
||||
$Element("pop_container").hide();
|
||||
$Element("pop_container2").show();
|
||||
callFileUploader();
|
||||
}
|
||||
fnUploadImage = $Fn(uploadImage,this);
|
||||
$Fn(closeWindow,this).attach(welBtnCancel.$value(), "click");
|
||||
};
|
||||
|
||||
/**
|
||||
* 서버로부터 받은 데이타를 에디터에 전달하고 창을 닫음.
|
||||
* @parameter aFileInfo [{},{},...]
|
||||
* @ex aFileInfo = [
|
||||
* {
|
||||
sFileName : "nmms_215646753.gif",
|
||||
sFileURL :"http://static.naver.net/www/u/2010/0611/nmms_215646753.gif",
|
||||
bNewLine : true
|
||||
},
|
||||
{
|
||||
sFileName : "btn_sch_over.gif",
|
||||
sFileURL :"http://static1.naver.net/w9/btn_sch_over.gif",
|
||||
bNewLine : true
|
||||
}
|
||||
* ]
|
||||
*/
|
||||
function setPhotoToEditor(oFileInfo){
|
||||
if (!!opener && !!opener.nhn && !!opener.nhn.husky && !!opener.nhn.husky.PopUpManager) {
|
||||
//스마트 에디터 플러그인을 통해서 넣는 방법 (oFileInfo는 Array)
|
||||
opener.nhn.husky.PopUpManager.setCallback(window, 'SET_PHOTO', [oFileInfo]);
|
||||
//본문에 바로 tag를 넣는 방법 (oFileInfo는 String으로 <img src=....> )
|
||||
//opener.nhn.husky.PopUpManager.setCallback(window, 'PASTE_HTML', [oFileInfo]);
|
||||
}
|
||||
}
|
||||
|
||||
// 2012.05 현재] jindo.$Ajax.prototype.request에서 file과 form을 지원하지 안함.
|
||||
jindo.$Ajax.prototype.request = function(oData) {
|
||||
this._status++;
|
||||
var t = this;
|
||||
var req = this._request;
|
||||
var opt = this._options;
|
||||
var data, v,a = [], data = "";
|
||||
var _timer = null;
|
||||
var url = this._url;
|
||||
this._is_abort = false;
|
||||
|
||||
if( opt.postBody && opt.type.toUpperCase()=="XHR" && opt.method.toUpperCase()!="GET"){
|
||||
if(typeof oData == 'string'){
|
||||
data = oData;
|
||||
}else{
|
||||
data = jindo.$Json(oData).toString();
|
||||
}
|
||||
}else if (typeof oData == "undefined" || !oData) {
|
||||
data = null;
|
||||
} else {
|
||||
data = oData;
|
||||
}
|
||||
|
||||
req.open(opt.method.toUpperCase(), url, opt.async);
|
||||
if (opt.sendheader) {
|
||||
if(!this._headers["Content-Type"]){
|
||||
req.setRequestHeader("Content-Type", "application/x-www-form-urlencoded; charset=utf-8");
|
||||
}
|
||||
req.setRequestHeader("charset", "utf-8");
|
||||
for (var x in this._headers) {
|
||||
if(this._headers.hasOwnProperty(x)){
|
||||
if (typeof this._headers[x] == "function")
|
||||
continue;
|
||||
req.setRequestHeader(x, String(this._headers[x]));
|
||||
}
|
||||
}
|
||||
}
|
||||
var navi = navigator.userAgent;
|
||||
if(req.addEventListener&&!(navi.indexOf("Opera") > -1)&&!(navi.indexOf("MSIE") > -1)){
|
||||
/*
|
||||
* opera 10.60에서 XMLHttpRequest에 addEventListener기 추가되었지만 정상적으로 동작하지 않아 opera는 무조건 dom1방식으로 지원함.
|
||||
* IE9에서도 opera와 같은 문제가 있음.
|
||||
*/
|
||||
if(this._loadFunc){ req.removeEventListener("load", this._loadFunc, false); }
|
||||
this._loadFunc = function(rq){
|
||||
clearTimeout(_timer);
|
||||
_timer = undefined;
|
||||
t._onload(rq);
|
||||
}
|
||||
req.addEventListener("load", this._loadFunc, false);
|
||||
}else{
|
||||
if (typeof req.onload != "undefined") {
|
||||
req.onload = function(rq){
|
||||
if(req.readyState == 4 && !t._is_abort){
|
||||
clearTimeout(_timer);
|
||||
_timer = undefined;
|
||||
t._onload(rq);
|
||||
}
|
||||
};
|
||||
} else {
|
||||
/*
|
||||
* IE6에서는 onreadystatechange가 동기적으로 실행되어 timeout이벤트가 발생안됨.
|
||||
* 그래서 interval로 체크하여 timeout이벤트가 정상적으로 발생되도록 수정. 비동기 방식일때만
|
||||
|
||||
*/
|
||||
if(window.navigator.userAgent.match(/(?:MSIE) ([0-9.]+)/)[1]==6&&opt.async){
|
||||
var onreadystatechange = function(rq){
|
||||
if(req.readyState == 4 && !t._is_abort){
|
||||
if(_timer){
|
||||
clearTimeout(_timer);
|
||||
_timer = undefined;
|
||||
}
|
||||
t._onload(rq);
|
||||
clearInterval(t._interval);
|
||||
t._interval = undefined;
|
||||
}
|
||||
};
|
||||
this._interval = setInterval(onreadystatechange,300);
|
||||
|
||||
}else{
|
||||
req.onreadystatechange = function(rq){
|
||||
if(req.readyState == 4){
|
||||
clearTimeout(_timer);
|
||||
_timer = undefined;
|
||||
t._onload(rq);
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
req.send(data);
|
||||
return this;
|
||||
};
|
||||
@@ -0,0 +1,31 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
||||
<html lang="ko">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>FileUploader Callback</title>
|
||||
</head>
|
||||
<body>
|
||||
<script type="text/javascript">
|
||||
// alert("callback");
|
||||
// document.domain 설정
|
||||
try { document.domain = "http://*.naver.com"; } catch(e) {}
|
||||
|
||||
// execute callback script
|
||||
var sUrl = document.location.search.substr(1);
|
||||
if (sUrl != "blank") {
|
||||
var oParameter = {}; // query array
|
||||
|
||||
sUrl.replace(/([^=]+)=([^&]*)(&|$)/g, function(){
|
||||
oParameter[arguments[1]] = arguments[2];
|
||||
return "";
|
||||
});
|
||||
|
||||
if ((oParameter.errstr || '').length) { // on error
|
||||
(parent.jindo.FileUploader._oCallback[oParameter.callback_func+'_error'])(oParameter);
|
||||
} else {
|
||||
(parent.jindo.FileUploader._oCallback[oParameter.callback_func+'_success'])(oParameter);
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,22 @@
|
||||
@charset "UTF-8";
|
||||
/*
|
||||
* jQuery File Upload Plugin NoScript CSS 1.2.0
|
||||
* https://github.com/blueimp/jQuery-File-Upload
|
||||
*
|
||||
* Copyright 2013, Sebastian Tschan
|
||||
* https://blueimp.net
|
||||
*
|
||||
* Licensed under the MIT license:
|
||||
* http://www.opensource.org/licenses/MIT
|
||||
*/
|
||||
|
||||
.fileinput-button input {
|
||||
position: static;
|
||||
opacity: 1;
|
||||
filter: none;
|
||||
font-size: inherit;
|
||||
direction: inherit;
|
||||
}
|
||||
.fileinput-button span {
|
||||
display: none;
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
@charset "UTF-8";
|
||||
/*
|
||||
* jQuery File Upload UI Plugin NoScript CSS 8.8.5
|
||||
* https://github.com/blueimp/jQuery-File-Upload
|
||||
*
|
||||
* Copyright 2012, Sebastian Tschan
|
||||
* https://blueimp.net
|
||||
*
|
||||
* Licensed under the MIT license:
|
||||
* http://www.opensource.org/licenses/MIT
|
||||
*/
|
||||
|
||||
.fileinput-button i,
|
||||
.fileupload-buttonbar .delete,
|
||||
.fileupload-buttonbar .toggle {
|
||||
display: none;
|
||||
}
|
||||
@@ -0,0 +1,57 @@
|
||||
@charset "UTF-8";
|
||||
/*
|
||||
* jQuery File Upload UI Plugin CSS 9.0.0
|
||||
* https://github.com/blueimp/jQuery-File-Upload
|
||||
*
|
||||
* Copyright 2010, Sebastian Tschan
|
||||
* https://blueimp.net
|
||||
*
|
||||
* Licensed under the MIT license:
|
||||
* http://www.opensource.org/licenses/MIT
|
||||
*/
|
||||
|
||||
.fileupload-buttonbar .btn,
|
||||
.fileupload-buttonbar .toggle {
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
.progress-animated .progress-bar,
|
||||
.progress-animated .bar {
|
||||
background: url("../img/progressbar.gif") !important;
|
||||
filter: none;
|
||||
}
|
||||
.fileupload-process {
|
||||
float: right;
|
||||
display: none;
|
||||
}
|
||||
.fileupload-processing .fileupload-process,
|
||||
.files .processing .preview {
|
||||
display: block;
|
||||
width: 32px;
|
||||
height: 32px;
|
||||
background: url("../img/loading.gif") center no-repeat;
|
||||
background-size: contain;
|
||||
}
|
||||
.files audio,
|
||||
.files video {
|
||||
max-width: 300px;
|
||||
}
|
||||
|
||||
@media (max-width: 767px) {
|
||||
.fileupload-buttonbar .toggle,
|
||||
.files .toggle,
|
||||
.files .btn span {
|
||||
display: none;
|
||||
}
|
||||
.files .name {
|
||||
width: 80px;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
.files audio,
|
||||
.files video {
|
||||
max-width: 80px;
|
||||
}
|
||||
.files img,
|
||||
.files canvas {
|
||||
max-width: 100%;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
@charset "UTF-8";
|
||||
/*
|
||||
* jQuery File Upload Plugin CSS 1.3.0
|
||||
* https://github.com/blueimp/jQuery-File-Upload
|
||||
*
|
||||
* Copyright 2013, Sebastian Tschan
|
||||
* https://blueimp.net
|
||||
*
|
||||
* Licensed under the MIT license:
|
||||
* http://www.opensource.org/licenses/MIT
|
||||
*/
|
||||
|
||||
.fileinput-button {
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
}
|
||||
.fileinput-button input {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
margin: 0;
|
||||
opacity: 0;
|
||||
-ms-filter: 'alpha(opacity=0)';
|
||||
font-size: 200px;
|
||||
direction: ltr;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
/* Fixes for IE < 8 */
|
||||
@media screen\9 {
|
||||
.fileinput-button input {
|
||||
filter: alpha(opacity=0);
|
||||
font-size: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,99 @@
|
||||
@charset "UTF-8";
|
||||
/*
|
||||
* jQuery File Upload Plugin CSS Example 8.8.2
|
||||
* https://github.com/blueimp/jQuery-File-Upload
|
||||
*
|
||||
* Copyright 2013, Sebastian Tschan
|
||||
* https://blueimp.net
|
||||
*
|
||||
* Licensed under the MIT license:
|
||||
* http://www.opensource.org/licenses/MIT
|
||||
*/
|
||||
|
||||
body {margin:0;padding:0;overflow-x:hidden}
|
||||
body,input,textarea,select,button,table{font-family:'돋움',Dotum,Helvetica,sans-serif;font-size:12px}
|
||||
|
||||
#pop_header{height:26px;padding:14px 0 0 20px;border-bottom:1px solid #ededeb;background:#f4f4f3}
|
||||
#pop_header h1{color:#333;font-size:14px;letter-spacing:-1px;margin:0;padding:0}
|
||||
|
||||
.content_container{padding:5px 10px}
|
||||
|
||||
.swfupload{OUTLINE-WIDTH: 0px; OUTLINE-STYLE: none; OUTLINE-COLOR: invert}
|
||||
|
||||
.pop_container .drag_area{overflow:hidden;overflow-y:auto;position:relative;width:100%;height:250px;margin-top:4px;border:1px solid #eceff2}
|
||||
.pop_container .blind{visibility:hidden;position:absolute;line-height:0}
|
||||
.pop_container .drag_area .bg{position:absolute;top:0;left:0;width:100%;height:250px;background: #fdfdfd url(../../../img/photoQuickPopup/bg_drag_image.png) 50% 50% no-repeat;}
|
||||
.pop_container .drag_area .showbg{display:block}
|
||||
.pop_container .drag_area .hidebg{display:none}
|
||||
|
||||
ul.sortable{margin:0;padding:0;*zoom:1}
|
||||
ul.sortable:after{display:block;clear:both;content:""}
|
||||
|
||||
.sortable > li{
|
||||
list-style:none;
|
||||
float: left;
|
||||
width: 110px;
|
||||
height:110px;
|
||||
overflow: hidden;
|
||||
text-align: center;
|
||||
margin: 4px 3px; border: 1px solid #DDDDDD;padding:1px; cursor: move;
|
||||
background: #ffffff;
|
||||
}
|
||||
.sortable > li:hover, .sortable > li.ui-sortable-helper{border:2px solid #E58524;padding:0;}
|
||||
|
||||
.sortable > li > div{
|
||||
background: #f7f7f7;
|
||||
color:#808080;
|
||||
margin:0;
|
||||
font-size:11px;
|
||||
height:106px;
|
||||
width:100%;
|
||||
overflow: hidden;
|
||||
white-space:nowrap;-o-text-overflow:ellipsis;text-overflow:ellipsis;
|
||||
position:relative;
|
||||
}
|
||||
.sortable > li > div > img{margin:3px;}
|
||||
.sortable > li > div .delete_img{position:absolute;top:0;right:0px;display:none}
|
||||
.sortable > li:hover > div .delete_img{display:block;cursor:pointer}
|
||||
.sortable > li.placeholder{
|
||||
border: dashed 2px #ccc;background-color:#FFF;padding:0;
|
||||
}
|
||||
|
||||
.btn {
|
||||
display: inline-block;
|
||||
margin-bottom: 0;
|
||||
font-weight: 400;
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
cursor: pointer;
|
||||
background-image: none;
|
||||
border: 1px solid transparent;
|
||||
white-space: nowrap;
|
||||
padding: 6px 12px;
|
||||
font-size: 12px;
|
||||
line-height: 1.42857143;
|
||||
border-radius: 4px;
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
.btn-success {
|
||||
color: #fff;
|
||||
background-color: #5cb85c;
|
||||
border-color: #4cae4c;
|
||||
}
|
||||
.btn:hover, .btn:focus {
|
||||
color: #333;
|
||||
text-decoration: none;
|
||||
}
|
||||
.btn-success:hover, .btn-success:focus, .btn-success:active, .btn-success.active, .open .dropdown-toggle.btn-success {
|
||||
color: #fff;
|
||||
background-color: #47a447;
|
||||
border-color: #398439;
|
||||
}
|
||||
.seletion_explain{margin:10px 0}
|
||||
.drag_explain{position:relative;height:36px}
|
||||
.drag_explain p {padding:12px 0 0 0;margin:0;}
|
||||
.file_selet_group{position:absolute;top:0;right:0}
|
||||
.btn_group{text-align:center}
|
||||
@@ -0,0 +1,43 @@
|
||||
<?php
|
||||
include_once("../../../../../common.php");
|
||||
// default redirection
|
||||
$url = $_REQUEST["callback"].'?callback_func='.$_REQUEST["callback_func"];
|
||||
$bSuccessUpload = is_uploaded_file($_FILES['Filedata']['tmp_name']);
|
||||
|
||||
$ym = date('ym', G5_SERVER_TIME);
|
||||
|
||||
$data_dir = G5_DATA_PATH.'/editor/'.$ym;
|
||||
$data_url = G5_DATA_URL.'/editor/'.$ym;
|
||||
|
||||
@mkdir($data_dir, G5_DIR_PERMISSION);
|
||||
@chmod($data_dir, G5_DIR_PERMISSION);
|
||||
|
||||
// SUCCESSFUL
|
||||
if(bSuccessUpload) {
|
||||
$tmp_name = $_FILES['Filedata']['tmp_name'];
|
||||
$name = $_FILES['Filedata']['name'];
|
||||
|
||||
$filename_ext = strtolower(array_pop(explode('.',$name)));
|
||||
|
||||
if (!preg_match("/(jpe?g|gif|bmp|png)$/i", $filename_ext)) {
|
||||
$url .= '&errstr='.$name;
|
||||
} else {
|
||||
|
||||
$file_name = sprintf('%u', ip2long($_SERVER['REMOTE_ADDR'])).'_'.get_microtime().".".$filename_ext;
|
||||
$save_dir = sprintf('%s/%s', $data_dir, $file_name);
|
||||
$save_url = sprintf('%s/%s', $data_url, $file_name);
|
||||
|
||||
@move_uploaded_file($tmp_name, $save_dir);
|
||||
|
||||
$url .= "&bNewLine=true";
|
||||
$url .= "&sFileName=".$name;
|
||||
$url .= "&sFileURL=".$save_url;
|
||||
}
|
||||
}
|
||||
// FAILED
|
||||
else {
|
||||
$url .= '&errstr=error';
|
||||
}
|
||||
|
||||
header('Location: '. $url);
|
||||
?>
|
||||
@@ -0,0 +1,47 @@
|
||||
<?php
|
||||
include_once("../../../../../common.php");
|
||||
|
||||
$ym = date('ym', G5_SERVER_TIME);
|
||||
|
||||
$data_dir = G5_DATA_PATH.'/editor/'.$ym;
|
||||
$data_url = G5_DATA_URL.'/editor/'.$ym;
|
||||
|
||||
@mkdir($data_dir, G5_DIR_PERMISSION);
|
||||
@chmod($data_dir, G5_DIR_PERMISSION);
|
||||
|
||||
$sFileInfo = '';
|
||||
$headers = array();
|
||||
|
||||
foreach($_SERVER as $k => $v) {
|
||||
if(substr($k, 0, 9) == "HTTP_FILE") {
|
||||
$k = substr(strtolower($k), 5);
|
||||
$headers[$k] = $v;
|
||||
}
|
||||
}
|
||||
|
||||
$file = new stdClass;
|
||||
//$file->name = str_replace("\0", "", rawurldecode($headers['file_name']));
|
||||
$file->name = str_replace("\0", "", rawurldecode($headers['file_name']));
|
||||
$file->size = $headers['file_size'];
|
||||
$file->content = file_get_contents("php://input");
|
||||
|
||||
$filename_ext = strtolower(array_pop(explode('.',$file->name)));
|
||||
|
||||
if (!preg_match("/(jpe?g|gif|bmp|png)$/i", $filename_ext)) {
|
||||
echo "NOTALLOW_".$file->name;
|
||||
exit;
|
||||
}
|
||||
|
||||
//$file_name = iconv("utf-8", "cp949", $file->name);
|
||||
$file_name = sprintf('%u', ip2long($_SERVER['REMOTE_ADDR'])).'_'.get_microtime().".".$filename_ext;
|
||||
$newPath = $data_dir."/".$file_name;
|
||||
$save_url = sprintf('%s/%s', $data_url, $file_name);
|
||||
|
||||
if(file_put_contents($newPath, $file->content)) {
|
||||
$sFileInfo .= "&bNewLine=true";
|
||||
$sFileInfo .= "&sFileName=".$file->name;
|
||||
$sFileInfo .= "&sFileURL=".$save_url;
|
||||
}
|
||||
|
||||
echo $sFileInfo;
|
||||
?>
|
||||
|
After Width: | Height: | Size: 850 B |
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 3.2 KiB |
|
After Width: | Height: | Size: 426 B |
@@ -0,0 +1,64 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html lang="ko">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1">
|
||||
<title>사진 첨부하기 :: SmartEditor2</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<!-- Generic page styles -->
|
||||
<link rel="stylesheet" href="css/style.css?v=140715">
|
||||
<!-- CSS to style the file input field as button and adjust the Bootstrap progress bars -->
|
||||
<link rel="stylesheet" href="css/jquery.fileupload.css">
|
||||
</head>
|
||||
<body>
|
||||
<div class="container pop_container">
|
||||
<!-- header -->
|
||||
<div id="pop_header">
|
||||
<h1>사진 첨부하기</h1>
|
||||
</div>
|
||||
<!-- //header -->
|
||||
<div class="content_container">
|
||||
<div class="drag_explain">
|
||||
<p>마우스로 드래그하여 순서를 바꿀수 있습니다.</p>
|
||||
<div class="file_selet_group">
|
||||
<span class="btn btn-success fileinput-button">
|
||||
<span>파일선택</span>
|
||||
<!-- The file input field used as target for the file upload widget -->
|
||||
<input id="fileupload" type="file" name="files[]" multiple accept="image/*">
|
||||
</span>
|
||||
<button type="button" class="btn btn-danger delete" id="all_remove_btn">
|
||||
<span>전체삭제</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="drag_area" id="drag_area">
|
||||
<ul class="sortable" id="sortable">
|
||||
</ul>
|
||||
<em class="blind">마우스로 드래그해서 이미지를 추가해주세요.</em><span id="guide_text" class="bg hidebg"></span>
|
||||
</div>
|
||||
<div class="seletion_explain">이미지는 한번에 10개까지 선택할수 있습니다.</div>
|
||||
<div class="btn_group">
|
||||
<button type="button" class="btn" id="img_upload_submit">
|
||||
<span>등록</span>
|
||||
</button>
|
||||
<button type="button" class="btn" id="close_w_btn" >
|
||||
<span>취소</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="./js/jquery-1.8.3.min.js"></script>
|
||||
<script src="./js/jquery-ui.min.js"></script>
|
||||
<!-- The Iframe Transport is required for browsers without support for XHR file uploads -->
|
||||
<script src="./js/jquery.iframe-transport.js"></script>
|
||||
|
||||
<script type="text/javascript" src="./swfupload/swfupload.js"></script>
|
||||
<script type="text/javascript" src="./swfupload/jquery.swfupload.js"></script>
|
||||
|
||||
<!-- The basic File Upload plugin -->
|
||||
<script src="./js/jquery.fileupload.js?v=140715"></script>
|
||||
|
||||
<script src="./js/basic.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,390 @@
|
||||
/**
|
||||
* Jindo Component
|
||||
* @version 1.0.3
|
||||
* NHN_Library:Jindo_Component-1.0.3;JavaScript Components for Jindo;
|
||||
* @include Component, UIComponent, FileUploader
|
||||
*/
|
||||
jindo.Component = jindo.$Class({
|
||||
_htEventHandler: null,
|
||||
_htOption: null,
|
||||
$init: function () {
|
||||
var aInstance = this.constructor.getInstance();
|
||||
aInstance.push(this);
|
||||
this._htEventHandler = {};
|
||||
this._htOption = {};
|
||||
this._htOption._htSetter = {};
|
||||
},
|
||||
option: function (sName, vValue) {
|
||||
switch (typeof sName) {
|
||||
case "undefined":
|
||||
return this._htOption;
|
||||
case "string":
|
||||
if (typeof vValue != "undefined") {
|
||||
if (sName == "htCustomEventHandler") {
|
||||
if (typeof this._htOption[sName] == "undefined") {
|
||||
this.attach(vValue);
|
||||
} else {
|
||||
return this;
|
||||
}
|
||||
}
|
||||
this._htOption[sName] = vValue;
|
||||
if (typeof this._htOption._htSetter[sName] == "function") {
|
||||
this._htOption._htSetter[sName](vValue);
|
||||
}
|
||||
} else {
|
||||
return this._htOption[sName];
|
||||
}
|
||||
break;
|
||||
case "object":
|
||||
for (var sKey in sName) {
|
||||
if (sKey == "htCustomEventHandler") {
|
||||
if (typeof this._htOption[sKey] == "undefined") {
|
||||
this.attach(sName[sKey]);
|
||||
} else {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
this._htOption[sKey] = sName[sKey];
|
||||
if (typeof this._htOption._htSetter[sKey] == "function") {
|
||||
this._htOption._htSetter[sKey](sName[sKey]);
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
return this;
|
||||
},
|
||||
optionSetter: function (sName, fSetter) {
|
||||
switch (typeof sName) {
|
||||
case "undefined":
|
||||
return this._htOption._htSetter;
|
||||
case "string":
|
||||
if (typeof fSetter != "undefined") {
|
||||
this._htOption._htSetter[sName] = jindo.$Fn(fSetter, this).bind();
|
||||
} else {
|
||||
return this._htOption._htSetter[sName];
|
||||
}
|
||||
break;
|
||||
case "object":
|
||||
for (var sKey in sName) {
|
||||
this._htOption._htSetter[sKey] = jindo.$Fn(sName[sKey], this).bind();
|
||||
}
|
||||
break;
|
||||
}
|
||||
return this;
|
||||
},
|
||||
fireEvent: function (sEvent, oEvent) {
|
||||
oEvent = oEvent || {};
|
||||
var fInlineHandler = this['on' + sEvent],
|
||||
aHandlerList = this._htEventHandler[sEvent] || [],
|
||||
bHasInlineHandler = typeof fInlineHandler == "function",
|
||||
bHasHandlerList = aHandlerList.length > 0;
|
||||
if (!bHasInlineHandler && !bHasHandlerList) {
|
||||
return true;
|
||||
}
|
||||
aHandlerList = aHandlerList.concat();
|
||||
oEvent.sType = sEvent;
|
||||
if (typeof oEvent._aExtend == 'undefined') {
|
||||
oEvent._aExtend = [];
|
||||
oEvent.stop = function () {
|
||||
if (oEvent._aExtend.length > 0) {
|
||||
oEvent._aExtend[oEvent._aExtend.length - 1].bCanceled = true;
|
||||
}
|
||||
};
|
||||
}
|
||||
oEvent._aExtend.push({
|
||||
sType: sEvent,
|
||||
bCanceled: false
|
||||
});
|
||||
var aArg = [oEvent],
|
||||
i, nLen;
|
||||
for (i = 2, nLen = arguments.length; i < nLen; i++) {
|
||||
aArg.push(arguments[i]);
|
||||
}
|
||||
if (bHasInlineHandler) {
|
||||
fInlineHandler.apply(this, aArg);
|
||||
}
|
||||
if (bHasHandlerList) {
|
||||
var fHandler;
|
||||
for (i = 0, fHandler;
|
||||
(fHandler = aHandlerList[i]); i++) {
|
||||
fHandler.apply(this, aArg);
|
||||
}
|
||||
}
|
||||
return !oEvent._aExtend.pop().bCanceled;
|
||||
},
|
||||
attach: function (sEvent, fHandlerToAttach) {
|
||||
if (arguments.length == 1) {
|
||||
jindo.$H(arguments[0]).forEach(jindo.$Fn(function (fHandler, sEvent) {
|
||||
this.attach(sEvent, fHandler);
|
||||
}, this).bind());
|
||||
return this;
|
||||
}
|
||||
var aHandler = this._htEventHandler[sEvent];
|
||||
if (typeof aHandler == 'undefined') {
|
||||
aHandler = this._htEventHandler[sEvent] = [];
|
||||
}
|
||||
aHandler.push(fHandlerToAttach);
|
||||
return this;
|
||||
},
|
||||
detach: function (sEvent, fHandlerToDetach) {
|
||||
if (arguments.length == 1) {
|
||||
jindo.$H(arguments[0]).forEach(jindo.$Fn(function (fHandler, sEvent) {
|
||||
this.detach(sEvent, fHandler);
|
||||
}, this).bind());
|
||||
return this;
|
||||
}
|
||||
var aHandler = this._htEventHandler[sEvent];
|
||||
if (aHandler) {
|
||||
for (var i = 0, fHandler;
|
||||
(fHandler = aHandler[i]); i++) {
|
||||
if (fHandler === fHandlerToDetach) {
|
||||
aHandler = aHandler.splice(i, 1);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return this;
|
||||
},
|
||||
detachAll: function (sEvent) {
|
||||
var aHandler = this._htEventHandler;
|
||||
if (arguments.length) {
|
||||
if (typeof aHandler[sEvent] == 'undefined') {
|
||||
return this;
|
||||
}
|
||||
delete aHandler[sEvent];
|
||||
return this;
|
||||
}
|
||||
for (var o in aHandler) {
|
||||
delete aHandler[o];
|
||||
}
|
||||
return this;
|
||||
}
|
||||
});
|
||||
jindo.Component.factory = function (aObject, htOption) {
|
||||
var aReturn = [],
|
||||
oInstance;
|
||||
if (typeof htOption == "undefined") {
|
||||
htOption = {};
|
||||
}
|
||||
for (var i = 0, el;
|
||||
(el = aObject[i]); i++) {
|
||||
oInstance = new this(el, htOption);
|
||||
aReturn[aReturn.length] = oInstance;
|
||||
}
|
||||
return aReturn;
|
||||
};
|
||||
jindo.Component.getInstance = function () {
|
||||
if (typeof this._aInstance == "undefined") {
|
||||
this._aInstance = [];
|
||||
}
|
||||
return this._aInstance;
|
||||
};
|
||||
jindo.UIComponent = jindo.$Class({
|
||||
$init: function () {
|
||||
this._bIsActivating = false;
|
||||
},
|
||||
isActivating: function () {
|
||||
return this._bIsActivating;
|
||||
},
|
||||
activate: function () {
|
||||
if (this.isActivating()) {
|
||||
return this;
|
||||
}
|
||||
this._bIsActivating = true;
|
||||
if (arguments.length > 0) {
|
||||
this._onActivate.apply(this, arguments);
|
||||
} else {
|
||||
this._onActivate();
|
||||
}
|
||||
return this;
|
||||
},
|
||||
deactivate: function () {
|
||||
if (!this.isActivating()) {
|
||||
return this;
|
||||
}
|
||||
this._bIsActivating = false;
|
||||
if (arguments.length > 0) {
|
||||
this._onDeactivate.apply(this, arguments);
|
||||
} else {
|
||||
this._onDeactivate();
|
||||
}
|
||||
return this;
|
||||
}
|
||||
}).extend(jindo.Component);
|
||||
jindo.FileUploader = jindo.$Class({
|
||||
_bIsActivating: false,
|
||||
_aHiddenInput: [],
|
||||
$init: function (elFileSelect, htOption) {
|
||||
var htDefaultOption = {
|
||||
sUrl: '',
|
||||
sCallback: '',
|
||||
htData: {},
|
||||
sFiletype: '*',
|
||||
sMsgNotAllowedExt: "업로드가 허용되지 않는 파일형식입니다",
|
||||
bAutoUpload: false,
|
||||
bAutoReset: true,
|
||||
bActivateOnload: true
|
||||
};
|
||||
this.option(htDefaultOption);
|
||||
this.option(htOption || {});
|
||||
this._el = jindo.$(elFileSelect);
|
||||
this._wel = jindo.$Element(this._el);
|
||||
this._elForm = this._el.form;
|
||||
this._aHiddenInput = [];
|
||||
this.constructor._oCallback = {};
|
||||
this._wfChange = jindo.$Fn(this._onFileSelectChange, this);
|
||||
if (this.option("bActivateOnload")) {
|
||||
this.activate();
|
||||
}
|
||||
},
|
||||
_appendIframe: function () {
|
||||
var sIframeName = 'tmpFrame_' + this._makeUniqueId();
|
||||
this._welIframe = jindo.$Element(jindo.$('<iframe name="' + sIframeName + '" src="' + this.option("sCallback") + '?blank">')).css({
|
||||
width: '10px',
|
||||
border: '2px',
|
||||
height: '10px',
|
||||
left: '10px',
|
||||
top: '10px'
|
||||
});
|
||||
document.body.appendChild(this._welIframe.$value());
|
||||
},
|
||||
_removeIframe: function () {
|
||||
this._welIframe.leave();
|
||||
},
|
||||
getBaseElement: function () {
|
||||
return this.getFileSelect();
|
||||
},
|
||||
getFileSelect: function () {
|
||||
return this._el;
|
||||
},
|
||||
getFormElement: function () {
|
||||
return this._elForm;
|
||||
},
|
||||
upload: function () {
|
||||
this._appendIframe();
|
||||
var elForm = this.getFormElement(),
|
||||
welForm = jindo.$Element(elForm),
|
||||
sIframeName = this._welIframe.attr("name"),
|
||||
sFunctionName = sIframeName + '_func',
|
||||
sAction = this.option("sUrl");
|
||||
welForm.attr({
|
||||
target: sIframeName,
|
||||
action: sAction
|
||||
});
|
||||
this._aHiddenInput.push(this._createElement('input', {
|
||||
'type': 'hidden',
|
||||
'name': 'callback',
|
||||
'value': this.option("sCallback")
|
||||
}));
|
||||
this._aHiddenInput.push(this._createElement('input', {
|
||||
'type': 'hidden',
|
||||
'name': 'callback_func',
|
||||
'value': sFunctionName
|
||||
}));
|
||||
for (var k in this.option("htData")) {
|
||||
this._aHiddenInput.push(this._createElement('input', {
|
||||
'type': 'hidden',
|
||||
'name': k,
|
||||
'value': this.option("htData")[k]
|
||||
}));
|
||||
}
|
||||
for (var i = 0; i < this._aHiddenInput.length; i++) {
|
||||
elForm.appendChild(this._aHiddenInput[i]);
|
||||
}
|
||||
this.constructor._oCallback[sFunctionName + '_success'] = jindo.$Fn(function (oParameter) {
|
||||
this.fireEvent("success", {
|
||||
htResult: oParameter
|
||||
});
|
||||
delete this.constructor._oCallback[oParameter.callback_func + '_success'];
|
||||
delete this.constructor._oCallback[oParameter.callback_func + '_error'];
|
||||
for (var i = 0; i < this._aHiddenInput.length; i++) {
|
||||
jindo.$Element(this._aHiddenInput[i]).leave();
|
||||
}
|
||||
this._aHiddenInput.length = 0;
|
||||
this._removeIframe();
|
||||
}, this).bind();
|
||||
this.constructor._oCallback[sFunctionName + '_error'] = jindo.$Fn(function (oParameter) {
|
||||
this.fireEvent("error", {
|
||||
htResult: oParameter
|
||||
});
|
||||
delete this.constructor._oCallback[oParameter.callback_func + '_success'];
|
||||
delete this.constructor._oCallback[oParameter.callback_func + '_error'];
|
||||
for (var i = 0; i < this._aHiddenInput.length; i++) {
|
||||
jindo.$Element(this._aHiddenInput[i]).leave();
|
||||
}
|
||||
this._aHiddenInput.length = 0;
|
||||
this._removeIframe();
|
||||
}, this).bind();
|
||||
|
||||
elForm.submit();
|
||||
if (this.option("bAutoReset")) {
|
||||
this.reset();
|
||||
}
|
||||
},
|
||||
reset: function () {
|
||||
var elWrapForm = jindo.$("<form>");
|
||||
this._wel.wrap(elWrapForm);
|
||||
elWrapForm.reset();
|
||||
jindo.$Element(elWrapForm).replace(this._el);
|
||||
var elForm = this.getFormElement(),
|
||||
welForm = jindo.$Element(elForm);
|
||||
welForm.attr({
|
||||
target: this._sPrevTarget,
|
||||
action: this._sAction
|
||||
});
|
||||
return this;
|
||||
},
|
||||
_onActivate: function () {
|
||||
var elForm = this.getFormElement(),
|
||||
welForm = jindo.$Element(elForm);
|
||||
this._sPrevTarget = welForm.attr("target");
|
||||
this._sAction = welForm.attr("action");
|
||||
this._el.value = "";
|
||||
this._wfChange.attach(this._el, "change");
|
||||
},
|
||||
_onDeactivate: function () {
|
||||
this._wfChange.detach(this._el, "change");
|
||||
},
|
||||
_makeUniqueId: function () {
|
||||
return new Date().getMilliseconds() + Math.floor(Math.random() * 100000);
|
||||
},
|
||||
_createElement: function (name, attributes) {
|
||||
var el = jindo.$("<" + name + ">");
|
||||
var wel = jindo.$Element(el);
|
||||
for (var k in attributes) {
|
||||
wel.attr(k, attributes[k]);
|
||||
}
|
||||
return el;
|
||||
},
|
||||
_checkExtension: function (sFile) {
|
||||
var aType = this.option("sFiletype").split(';');
|
||||
for (var i = 0, sType; i < aType.length; i++) {
|
||||
sType = (aType[i] == "*.*") ? "*" : aType[i];
|
||||
sType = sType.replace(/^\s+|\s+$/, '');
|
||||
sType = sType.replace(/\./g, '\\.');
|
||||
sType = sType.replace(/\*/g, '[^\\\/]+');
|
||||
if ((new RegExp(sType + '$', 'gi')).test(sFile)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
},
|
||||
_onFileSelectChange: function (we) {
|
||||
var sValue = we.element.value,
|
||||
bAllowed = this._checkExtension(sValue),
|
||||
htParam = {
|
||||
sValue: sValue,
|
||||
bAllowed: bAllowed,
|
||||
sMsgNotAllowedExt: this.option("sMsgNotAllowedExt")
|
||||
};
|
||||
if (sValue.length && this.fireEvent("select", htParam)) {
|
||||
if (bAllowed) {
|
||||
if (this.option("bAutoUpload")) {
|
||||
this.upload();
|
||||
}
|
||||
} else {
|
||||
alert(htParam.sMsgNotAllowedExt);
|
||||
}
|
||||
}
|
||||
}
|
||||
}).extend(jindo.UIComponent);
|
||||
@@ -0,0 +1,339 @@
|
||||
jQuery.fn.bindAll = function(options) {
|
||||
var $this = this;
|
||||
jQuery.each(options, function(key, val){
|
||||
$this.bind(key, val);
|
||||
});
|
||||
return this;
|
||||
}
|
||||
|
||||
jQuery(function ($) {
|
||||
'use strict';
|
||||
// Change this to the location of your server-side upload handler:
|
||||
var gnu = {
|
||||
url : './php/',
|
||||
container_el : 'body',
|
||||
dreg_area : '#drag_area',
|
||||
dreg_area_list : '#drag_area > ul',
|
||||
progress_bar : '#progress .progress-bar',
|
||||
filter : /^(image\/bmp|image\/gif|image\/jpg|image\/jpeg|image\/png)$/i,
|
||||
files : [],
|
||||
file_limit : 10, //한번에 올릴수 파일갯수 제한
|
||||
imgw : 100,
|
||||
imgh : 70,
|
||||
file_api_support : !!(window.ProgressEvent && window.FileReader),
|
||||
$elTextGuide : $("#guide_text"),
|
||||
init : function(){
|
||||
$(this.dreg_area_list).sortable({
|
||||
'cursor':'pointer',
|
||||
'placeholder':'placeholder'
|
||||
});
|
||||
$(this.dreg_area_list).disableSelection();
|
||||
if( this.file_api_support ) this.$elTextGuide.removeClass("hidebg").addClass("showbg");
|
||||
},
|
||||
file_push : function(file){
|
||||
var othis = this,
|
||||
last = othis.files.length;
|
||||
|
||||
othis.files.push(file);
|
||||
},
|
||||
_readymodebg : function(){
|
||||
if( this.file_api_support ) {
|
||||
var sClass = this.$elTextGuide.attr('class');
|
||||
if(sClass.indexOf('hidebg') > 0){
|
||||
this.$elTextGuide.removeClass('hidebg');
|
||||
this.$elTextGuide.addClass('showbg');
|
||||
}
|
||||
}
|
||||
},
|
||||
_startmodebg : function(){
|
||||
if( this.file_api_support ) {
|
||||
var sClass = this.$elTextGuide.attr('class');
|
||||
if(sClass.indexOf('hidebg') < 0){
|
||||
this.$elTextGuide.removeClass('showbg');
|
||||
this.$elTextGuide.addClass('hidebg');
|
||||
}
|
||||
}
|
||||
},
|
||||
_delete : function(e){
|
||||
e.preventDefault();
|
||||
var othis = gnu,
|
||||
$button = $(e.currentTarget),
|
||||
delete_url = $button.attr("data-delete");
|
||||
if( delete_url ){
|
||||
$.ajax({
|
||||
url: othis.url+"?del=1&file="+ delete_url
|
||||
}).done(function (result) {
|
||||
});
|
||||
}
|
||||
$button.parents('li.sort_list').fadeOut(300, function(){
|
||||
$(this).remove();
|
||||
var $dreg_area = $(othis.dreg_area_list);
|
||||
$dreg_area.sortable('refresh');
|
||||
if( !$dreg_area.children('li').length ) othis._readymodebg();
|
||||
});
|
||||
},
|
||||
_add : function(e, data, preload){
|
||||
var othis = this;
|
||||
othis._startmodebg();
|
||||
data.context = $('<li/>').addClass("sort_list").appendTo(this.dreg_area_list);
|
||||
$.each(data.files, function (index, file) {
|
||||
if ( !preload && !othis.filter.test(file.type)) {
|
||||
data.context.remove();
|
||||
alert('이미지만 허용합니다.');
|
||||
return true;
|
||||
}
|
||||
var node = $('<div/>')
|
||||
.append($('<span/>').text(file.name))
|
||||
.append($('<span/>').addClass("delete_img").attr({"data-delete":file.name,"data-url":file.url}).html("<img src='./img/system_delete.png' alt='삭제' title='삭제' >")),
|
||||
$img = "<img src='./img/loading.gif' class='pre_thumb' />",
|
||||
size_text = '';
|
||||
|
||||
if ( preload && preload != 'swfupload' ){
|
||||
var ret = othis.get_ratio( file.width, file.height ),
|
||||
size_text = file.width+" x "+file.height;
|
||||
$img = "<img src='"+file.url+"' width='"+ret['width']+"' height='"+ret['height']+"' class='pre_thumb' />";
|
||||
|
||||
}
|
||||
if (!index) {
|
||||
node
|
||||
.prepend('<br>')
|
||||
.prepend($img);
|
||||
if(size_text){
|
||||
node.append('<br>')
|
||||
.append($('<span/>').text(size_text))
|
||||
}
|
||||
}
|
||||
node.appendTo(data.context);
|
||||
node.find(".delete_img").on("click", othis._delete);
|
||||
});
|
||||
$(othis.dreg_area_list).sortable('refresh');
|
||||
},
|
||||
get_file_all : function(){
|
||||
var othis = this,
|
||||
oDate = new Date();
|
||||
$.ajax({
|
||||
// Uncomment the following to send cross-domain cookies:
|
||||
//xhrFields: {withCredentials: true},
|
||||
//url: $('#fileupload').fileupload('option', 'url'),
|
||||
url: this.url+"?t="+ oDate.getTime(),
|
||||
dataType: 'json',
|
||||
context: $('#fileupload')[0]
|
||||
}).always(function () {
|
||||
//$(this).removeClass('fileupload-processing');
|
||||
}).done(function (result) {
|
||||
$.each(result.files, function (index, data) {
|
||||
var tmp = { files : [] };
|
||||
tmp.files[0] = data;
|
||||
othis._add( $.Event('add'), tmp, 'preload' );
|
||||
});
|
||||
});
|
||||
},
|
||||
_processalways : function(e, data){
|
||||
var index = data.index,
|
||||
file = data.files[index],
|
||||
node = $(data.context.children()[index]);
|
||||
if (file.error) {
|
||||
node
|
||||
.append('<br>')
|
||||
.append($('<span class="text-danger"/>').text(file.error));
|
||||
}
|
||||
if (index + 1 === data.files.length) {
|
||||
data.context.find('button')
|
||||
.text('Upload')
|
||||
.prop('disabled', !!data.files.error);
|
||||
}
|
||||
},
|
||||
obj_to_arr : function(obj){
|
||||
var array = $.map(obj, function(value, index) {
|
||||
return [value];
|
||||
});
|
||||
return array;
|
||||
},
|
||||
_done : function(e, data){
|
||||
var othis = this;
|
||||
$.each(data.result.files, function (index, file) {
|
||||
if (file.url) {
|
||||
var ret = othis.get_ratio( file.width, file.height ),
|
||||
node = $(data.context.children()[index]),
|
||||
size_text = file.width+" x "+file.height,
|
||||
//$img = "<img src='"+file.url+"' width='"+ret['width']+"' height='"+ret['height']+"' />",
|
||||
link = $('<a>')
|
||||
.attr('target', '_blank')
|
||||
.prop('href', file.url);
|
||||
node
|
||||
//.wrap(link)
|
||||
.append('<br>')
|
||||
.append($('<span/>').text(size_text))
|
||||
.find("img.pre_thumb").attr({"src":file.url,"width":ret['width'],"height":ret['height']})
|
||||
.end().find(".delete_img").attr({"data-delete":file.name,"data-url":file.url});
|
||||
} else if (file.error) {
|
||||
var error = $('<span class="text-danger"/>').text(file.error);
|
||||
$(data.context.children()[index])
|
||||
.append('<br>')
|
||||
.append(error);
|
||||
}
|
||||
othis.file_push(file);
|
||||
});
|
||||
},
|
||||
get_ratio : function(width, height){
|
||||
var ratio = 0,
|
||||
ret_img = [];
|
||||
if( !width || !height ){
|
||||
ret_img['width'] = this.imgw;
|
||||
ret_img['height'] = this.imgh;
|
||||
return ret_img;
|
||||
}
|
||||
if(width > this.imgw){
|
||||
ratio = this.imgw / width;
|
||||
height = height * ratio;
|
||||
width = this.imgw;
|
||||
}
|
||||
if( height > this.imgh ){
|
||||
ratio = this.imgh / height;
|
||||
width = width * ratio;
|
||||
height = this.imgh;
|
||||
}
|
||||
ret_img['width'] = parseInt(width);
|
||||
ret_img['height'] = parseInt(height);
|
||||
return ret_img;
|
||||
},
|
||||
setPhotoToEditor : function(oFileInfo){
|
||||
if (!!opener && !!opener.nhn && !!opener.nhn.husky && !!opener.nhn.husky.PopUpManager) {
|
||||
//스마트 에디터 플러그인을 통해서 넣는 방법 (oFileInfo는 Array)
|
||||
opener.nhn.husky.PopUpManager.setCallback(window, 'SET_PHOTO', [oFileInfo]);
|
||||
//본문에 바로 tag를 넣는 방법 (oFileInfo는 String으로 <img src=....> )
|
||||
//opener.nhn.husky.PopUpManager.setCallback(window, 'PASTE_HTML', [oFileInfo]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$('#fileupload').fileupload({
|
||||
url: gnu.url,
|
||||
dataType: 'json',
|
||||
container_el: gnu.container_el,
|
||||
dropZone: $(gnu.dreg_area),
|
||||
autoUpload: true,
|
||||
sequentialUploads: true,
|
||||
acceptFileTypes: /(\.|\/)(gif|jpe?g|bmp|png)$/i,
|
||||
// Enable image resizing, except for Android and Opera,
|
||||
// which actually support image resizing, but fail to
|
||||
// send Blob objects via XHR requests:
|
||||
disableImageResize: true,
|
||||
limit_filesLength : gnu.file_limit
|
||||
}).on('fileuploadadd', function (e, data) {
|
||||
gnu._add(e, data);
|
||||
}).on('fileuploadprocessalways', function (e, data) {
|
||||
gnu._processalways(e, data);
|
||||
}).on('fileuploaddone', function (e, data) {
|
||||
|
||||
gnu._done( e, data );
|
||||
|
||||
}).on('fileuploadfail', function (e, data) {
|
||||
$.each(data.files, function (index, file) {
|
||||
var error = $('<span class="text-danger"/>').text('File upload failed.');
|
||||
$(data.context.children()[index])
|
||||
.append('<br>')
|
||||
.append(error);
|
||||
});
|
||||
}).prop('disabled', !$.support.fileInput)
|
||||
.parent().addClass($.support.fileInput ? undefined : 'disabled');
|
||||
|
||||
gnu.init();
|
||||
|
||||
var listeners = {
|
||||
data : {},
|
||||
log : false,
|
||||
swfuploadLoaded: function(event){
|
||||
if(this.log) $('.log', this).append('<li>Loaded</li>');
|
||||
},
|
||||
fileQueued: function(event, file){
|
||||
if(this.log) $('.log', this).append('<li>File queued - '+file.name+'</li>');
|
||||
// start the upload once it is queued
|
||||
// but only if this queue is not disabled
|
||||
if (!$('input[name=disabled]:checked', this).length) {
|
||||
$(this).swfupload('startUpload');
|
||||
}
|
||||
},
|
||||
fileQueueError: function(event, file, errorCode, message){
|
||||
switch (errorCode)
|
||||
{
|
||||
case -100 :
|
||||
alert("파일을 "+message+"개 이하로 선택해주세요.");
|
||||
break;
|
||||
}
|
||||
if(this.log) $('.log', this).append('<li>File queue error - '+message+'</li>');
|
||||
},
|
||||
fileDialogStart: function(event){
|
||||
if(this.log) $('.log', this).append('<li>File dialog start</li>');
|
||||
},
|
||||
fileDialogComplete: function(event, numFilesSelected, numFilesQueued){
|
||||
if(this.log) $('.log', this).append('<li>File dialog complete</li>');
|
||||
},
|
||||
uploadStart: function(event, file){
|
||||
listeners.data.files = $.makeArray(file);
|
||||
gnu._add( event, listeners.data, 'swfupload' );
|
||||
if(this.log) $('.log', this).append('<li>Upload start - '+file.name+'</li>');
|
||||
},
|
||||
uploadProgress: function(event, file, bytesLoaded){
|
||||
if(this.log) $('.log', this).append('<li>Upload progress - '+bytesLoaded+'</li>');
|
||||
},
|
||||
uploadSuccess: function(event, file, serverData){
|
||||
listeners.data.result = jQuery.parseJSON( serverData );
|
||||
gnu._done( event, listeners.data );
|
||||
if(this.log) $('.log', this).append('<li>Upload success - '+file.name+'</li>');
|
||||
|
||||
},
|
||||
uploadComplete: function(event, file){
|
||||
if(this.log) $('.log', this).append('<li>Upload complete - '+file.name+'</li>');
|
||||
// upload has completed, lets try the next one in the queue
|
||||
// but only if this queue is not disabled
|
||||
if (!$('input[name=disabled]:checked', this).length) {
|
||||
$(this).swfupload('startUpload');
|
||||
}
|
||||
},
|
||||
uploadError: function(event, file, errorCode, message){
|
||||
if(this.log) $('.log', this).append('<li>Upload error - '+message+'</li>');
|
||||
}
|
||||
};
|
||||
|
||||
$(gnu.container_el).bindAll(listeners);
|
||||
/* listeners이벤트 */
|
||||
|
||||
$(gnu.dreg_area).bind('drop dragover', function (e) {
|
||||
e.preventDefault();
|
||||
if( !gnu.file_api_support && e.type == 'drop' ) alert("브라우저가 드래그 앤 드랍을 지원하지 않습니다.");
|
||||
});
|
||||
$("#all_remove_btn").bind("click", function(e){
|
||||
e.preventDefault();
|
||||
if( $(gnu.dreg_area_list).children().length ){
|
||||
if (confirm("추가한 이미지가 있습니다.정말 삭제 하시겠습니까?")){
|
||||
$(gnu.dreg_area_list).find(".delete_img").each( function(i){
|
||||
$(this).trigger("click");
|
||||
});
|
||||
$(gnu.dreg_area_list).sortable('refresh');
|
||||
}
|
||||
}
|
||||
});
|
||||
$("#img_upload_submit").bind("click", function(e){
|
||||
e.preventDefault();
|
||||
var aResult = [], j = 0;
|
||||
$(gnu.dreg_area_list).find(".delete_img").each( function(i, f){
|
||||
if( !$(this).attr("data-url") ) return true;
|
||||
aResult[j] = [];
|
||||
aResult[j]['bNewLine'] = 'true';
|
||||
aResult[j]['sAlign'] = '';
|
||||
aResult[j]['sFileName'] = $(this).attr("data-delete");
|
||||
aResult[j]['sFileURL'] = $(this).attr("data-url");
|
||||
j++;
|
||||
});
|
||||
if( aResult.length ){
|
||||
gnu.setPhotoToEditor(aResult);
|
||||
aResult = null;
|
||||
}
|
||||
window.close();
|
||||
});
|
||||
$("#close_w_btn").bind("click", function(e){
|
||||
e.preventDefault();
|
||||
window.close();
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,172 @@
|
||||
/*
|
||||
* jQuery File Upload Processing Plugin 1.3.0
|
||||
* https://github.com/blueimp/jQuery-File-Upload
|
||||
*
|
||||
* Copyright 2012, Sebastian Tschan
|
||||
* https://blueimp.net
|
||||
*
|
||||
* Licensed under the MIT license:
|
||||
* http://www.opensource.org/licenses/MIT
|
||||
*/
|
||||
|
||||
/* jshint nomen:false */
|
||||
/* global define, window */
|
||||
|
||||
(function (factory) {
|
||||
'use strict';
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// Register as an anonymous AMD module:
|
||||
define([
|
||||
'jquery',
|
||||
'./jquery.fileupload'
|
||||
], factory);
|
||||
} else {
|
||||
// Browser globals:
|
||||
factory(
|
||||
window.jQuery
|
||||
);
|
||||
}
|
||||
}(function ($) {
|
||||
'use strict';
|
||||
|
||||
var originalAdd = $.blueimp.fileupload.prototype.options.add;
|
||||
|
||||
// The File Upload Processing plugin extends the fileupload widget
|
||||
// with file processing functionality:
|
||||
$.widget('blueimp.fileupload', $.blueimp.fileupload, {
|
||||
|
||||
options: {
|
||||
// The list of processing actions:
|
||||
processQueue: [
|
||||
/*
|
||||
{
|
||||
action: 'log',
|
||||
type: 'debug'
|
||||
}
|
||||
*/
|
||||
],
|
||||
add: function (e, data) {
|
||||
var $this = $(this);
|
||||
data.process(function () {
|
||||
return $this.fileupload('process', data);
|
||||
});
|
||||
originalAdd.call(this, e, data);
|
||||
}
|
||||
},
|
||||
|
||||
processActions: {
|
||||
/*
|
||||
log: function (data, options) {
|
||||
console[options.type](
|
||||
'Processing "' + data.files[data.index].name + '"'
|
||||
);
|
||||
}
|
||||
*/
|
||||
},
|
||||
|
||||
_processFile: function (data, originalData) {
|
||||
var that = this,
|
||||
dfd = $.Deferred().resolveWith(that, [data]),
|
||||
chain = dfd.promise();
|
||||
this._trigger('process', null, data);
|
||||
$.each(data.processQueue, function (i, settings) {
|
||||
var func = function (data) {
|
||||
if (originalData.errorThrown) {
|
||||
return $.Deferred()
|
||||
.rejectWith(that, [originalData]).promise();
|
||||
}
|
||||
return that.processActions[settings.action].call(
|
||||
that,
|
||||
data,
|
||||
settings
|
||||
);
|
||||
};
|
||||
chain = chain.pipe(func, settings.always && func);
|
||||
});
|
||||
chain
|
||||
.done(function () {
|
||||
that._trigger('processdone', null, data);
|
||||
that._trigger('processalways', null, data);
|
||||
})
|
||||
.fail(function () {
|
||||
that._trigger('processfail', null, data);
|
||||
that._trigger('processalways', null, data);
|
||||
});
|
||||
return chain;
|
||||
},
|
||||
|
||||
// Replaces the settings of each processQueue item that
|
||||
// are strings starting with an "@", using the remaining
|
||||
// substring as key for the option map,
|
||||
// e.g. "@autoUpload" is replaced with options.autoUpload:
|
||||
_transformProcessQueue: function (options) {
|
||||
var processQueue = [];
|
||||
$.each(options.processQueue, function () {
|
||||
var settings = {},
|
||||
action = this.action,
|
||||
prefix = this.prefix === true ? action : this.prefix;
|
||||
$.each(this, function (key, value) {
|
||||
if ($.type(value) === 'string' &&
|
||||
value.charAt(0) === '@') {
|
||||
settings[key] = options[
|
||||
value.slice(1) || (prefix ? prefix +
|
||||
key.charAt(0).toUpperCase() + key.slice(1) : key)
|
||||
];
|
||||
} else {
|
||||
settings[key] = value;
|
||||
}
|
||||
|
||||
});
|
||||
processQueue.push(settings);
|
||||
});
|
||||
options.processQueue = processQueue;
|
||||
},
|
||||
|
||||
// Returns the number of files currently in the processsing queue:
|
||||
processing: function () {
|
||||
return this._processing;
|
||||
},
|
||||
|
||||
// Processes the files given as files property of the data parameter,
|
||||
// returns a Promise object that allows to bind callbacks:
|
||||
process: function (data) {
|
||||
var that = this,
|
||||
options = $.extend({}, this.options, data);
|
||||
if (options.processQueue && options.processQueue.length) {
|
||||
this._transformProcessQueue(options);
|
||||
if (this._processing === 0) {
|
||||
this._trigger('processstart');
|
||||
}
|
||||
$.each(data.files, function (index) {
|
||||
var opts = index ? $.extend({}, options) : options,
|
||||
func = function () {
|
||||
if (data.errorThrown) {
|
||||
return $.Deferred()
|
||||
.rejectWith(that, [data]).promise();
|
||||
}
|
||||
return that._processFile(opts, data);
|
||||
};
|
||||
opts.index = index;
|
||||
that._processing += 1;
|
||||
that._processingQueue = that._processingQueue.pipe(func, func)
|
||||
.always(function () {
|
||||
that._processing -= 1;
|
||||
if (that._processing === 0) {
|
||||
that._trigger('processstop');
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
return this._processingQueue;
|
||||
},
|
||||
|
||||
_create: function () {
|
||||
this._super();
|
||||
this._processing = 0;
|
||||
this._processingQueue = $.Deferred().resolveWith(this)
|
||||
.promise();
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
}));
|
||||
@@ -0,0 +1,699 @@
|
||||
/*
|
||||
* jQuery File Upload User Interface Plugin 9.5.2
|
||||
* https://github.com/blueimp/jQuery-File-Upload
|
||||
*
|
||||
* Copyright 2010, Sebastian Tschan
|
||||
* https://blueimp.net
|
||||
*
|
||||
* Licensed under the MIT license:
|
||||
* http://www.opensource.org/licenses/MIT
|
||||
*/
|
||||
|
||||
/* jshint nomen:false */
|
||||
/* global define, window */
|
||||
|
||||
(function (factory) {
|
||||
'use strict';
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// Register as an anonymous AMD module:
|
||||
define([
|
||||
'jquery',
|
||||
'tmpl',
|
||||
'./jquery.fileupload-image',
|
||||
'./jquery.fileupload-audio',
|
||||
'./jquery.fileupload-video',
|
||||
'./jquery.fileupload-validate'
|
||||
], factory);
|
||||
} else {
|
||||
// Browser globals:
|
||||
factory(
|
||||
window.jQuery,
|
||||
window.tmpl
|
||||
);
|
||||
}
|
||||
}(function ($, tmpl) {
|
||||
'use strict';
|
||||
|
||||
$.blueimp.fileupload.prototype._specialOptions.push(
|
||||
'filesContainer',
|
||||
'uploadTemplateId',
|
||||
'downloadTemplateId'
|
||||
);
|
||||
|
||||
// The UI version extends the file upload widget
|
||||
// and adds complete user interface interaction:
|
||||
$.widget('blueimp.fileupload', $.blueimp.fileupload, {
|
||||
|
||||
options: {
|
||||
// By default, files added to the widget are uploaded as soon
|
||||
// as the user clicks on the start buttons. To enable automatic
|
||||
// uploads, set the following option to true:
|
||||
autoUpload: false,
|
||||
// The ID of the upload template:
|
||||
uploadTemplateId: 'template-upload',
|
||||
// The ID of the download template:
|
||||
downloadTemplateId: 'template-download',
|
||||
// The container for the list of files. If undefined, it is set to
|
||||
// an element with class "files" inside of the widget element:
|
||||
filesContainer: undefined,
|
||||
// By default, files are appended to the files container.
|
||||
// Set the following option to true, to prepend files instead:
|
||||
prependFiles: false,
|
||||
// The expected data type of the upload response, sets the dataType
|
||||
// option of the $.ajax upload requests:
|
||||
dataType: 'json',
|
||||
|
||||
// Function returning the current number of files,
|
||||
// used by the maxNumberOfFiles validation:
|
||||
getNumberOfFiles: function () {
|
||||
return this.filesContainer.children()
|
||||
.not('.processing').length;
|
||||
},
|
||||
|
||||
// Callback to retrieve the list of files from the server response:
|
||||
getFilesFromResponse: function (data) {
|
||||
if (data.result && $.isArray(data.result.files)) {
|
||||
return data.result.files;
|
||||
}
|
||||
return [];
|
||||
},
|
||||
|
||||
// The add callback is invoked as soon as files are added to the fileupload
|
||||
// widget (via file input selection, drag & drop or add API call).
|
||||
// See the basic file upload widget for more information:
|
||||
add: function (e, data) {
|
||||
if (e.isDefaultPrevented()) {
|
||||
return false;
|
||||
}
|
||||
var $this = $(this),
|
||||
that = $this.data('blueimp-fileupload') ||
|
||||
$this.data('fileupload'),
|
||||
options = that.options;
|
||||
data.context = that._renderUpload(data.files)
|
||||
.data('data', data)
|
||||
.addClass('processing');
|
||||
options.filesContainer[
|
||||
options.prependFiles ? 'prepend' : 'append'
|
||||
](data.context);
|
||||
that._forceReflow(data.context);
|
||||
that._transition(data.context);
|
||||
data.process(function () {
|
||||
return $this.fileupload('process', data);
|
||||
}).always(function () {
|
||||
data.context.each(function (index) {
|
||||
$(this).find('.size').text(
|
||||
that._formatFileSize(data.files[index].size)
|
||||
);
|
||||
}).removeClass('processing');
|
||||
that._renderPreviews(data);
|
||||
}).done(function () {
|
||||
data.context.find('.start').prop('disabled', false);
|
||||
if ((that._trigger('added', e, data) !== false) &&
|
||||
(options.autoUpload || data.autoUpload) &&
|
||||
data.autoUpload !== false) {
|
||||
data.submit();
|
||||
}
|
||||
}).fail(function () {
|
||||
if (data.files.error) {
|
||||
data.context.each(function (index) {
|
||||
var error = data.files[index].error;
|
||||
if (error) {
|
||||
$(this).find('.error').text(error);
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// Callback for the start of each file upload request:
|
||||
send: function (e, data) {
|
||||
if (e.isDefaultPrevented()) {
|
||||
return false;
|
||||
}
|
||||
var that = $(this).data('blueimp-fileupload') ||
|
||||
$(this).data('fileupload');
|
||||
if (data.context && data.dataType &&
|
||||
data.dataType.substr(0, 6) === 'iframe') {
|
||||
// Iframe Transport does not support progress events.
|
||||
// In lack of an indeterminate progress bar, we set
|
||||
// the progress to 100%, showing the full animated bar:
|
||||
data.context
|
||||
.find('.progress').addClass(
|
||||
!$.support.transition && 'progress-animated'
|
||||
)
|
||||
.attr('aria-valuenow', 100)
|
||||
.children().first().css(
|
||||
'width',
|
||||
'100%'
|
||||
);
|
||||
}
|
||||
return that._trigger('sent', e, data);
|
||||
},
|
||||
// Callback for successful uploads:
|
||||
done: function (e, data) {
|
||||
if (e.isDefaultPrevented()) {
|
||||
return false;
|
||||
}
|
||||
var that = $(this).data('blueimp-fileupload') ||
|
||||
$(this).data('fileupload'),
|
||||
getFilesFromResponse = data.getFilesFromResponse ||
|
||||
that.options.getFilesFromResponse,
|
||||
files = getFilesFromResponse(data),
|
||||
template,
|
||||
deferred;
|
||||
if (data.context) {
|
||||
data.context.each(function (index) {
|
||||
var file = files[index] ||
|
||||
{error: 'Empty file upload result'};
|
||||
deferred = that._addFinishedDeferreds();
|
||||
that._transition($(this)).done(
|
||||
function () {
|
||||
var node = $(this);
|
||||
template = that._renderDownload([file])
|
||||
.replaceAll(node);
|
||||
that._forceReflow(template);
|
||||
that._transition(template).done(
|
||||
function () {
|
||||
data.context = $(this);
|
||||
that._trigger('completed', e, data);
|
||||
that._trigger('finished', e, data);
|
||||
deferred.resolve();
|
||||
}
|
||||
);
|
||||
}
|
||||
);
|
||||
});
|
||||
} else {
|
||||
template = that._renderDownload(files)[
|
||||
that.options.prependFiles ? 'prependTo' : 'appendTo'
|
||||
](that.options.filesContainer);
|
||||
that._forceReflow(template);
|
||||
deferred = that._addFinishedDeferreds();
|
||||
that._transition(template).done(
|
||||
function () {
|
||||
data.context = $(this);
|
||||
that._trigger('completed', e, data);
|
||||
that._trigger('finished', e, data);
|
||||
deferred.resolve();
|
||||
}
|
||||
);
|
||||
}
|
||||
},
|
||||
// Callback for failed (abort or error) uploads:
|
||||
fail: function (e, data) {
|
||||
if (e.isDefaultPrevented()) {
|
||||
return false;
|
||||
}
|
||||
var that = $(this).data('blueimp-fileupload') ||
|
||||
$(this).data('fileupload'),
|
||||
template,
|
||||
deferred;
|
||||
if (data.context) {
|
||||
data.context.each(function (index) {
|
||||
if (data.errorThrown !== 'abort') {
|
||||
var file = data.files[index];
|
||||
file.error = file.error || data.errorThrown ||
|
||||
true;
|
||||
deferred = that._addFinishedDeferreds();
|
||||
that._transition($(this)).done(
|
||||
function () {
|
||||
var node = $(this);
|
||||
template = that._renderDownload([file])
|
||||
.replaceAll(node);
|
||||
that._forceReflow(template);
|
||||
that._transition(template).done(
|
||||
function () {
|
||||
data.context = $(this);
|
||||
that._trigger('failed', e, data);
|
||||
that._trigger('finished', e, data);
|
||||
deferred.resolve();
|
||||
}
|
||||
);
|
||||
}
|
||||
);
|
||||
} else {
|
||||
deferred = that._addFinishedDeferreds();
|
||||
that._transition($(this)).done(
|
||||
function () {
|
||||
$(this).remove();
|
||||
that._trigger('failed', e, data);
|
||||
that._trigger('finished', e, data);
|
||||
deferred.resolve();
|
||||
}
|
||||
);
|
||||
}
|
||||
});
|
||||
} else if (data.errorThrown !== 'abort') {
|
||||
data.context = that._renderUpload(data.files)[
|
||||
that.options.prependFiles ? 'prependTo' : 'appendTo'
|
||||
](that.options.filesContainer)
|
||||
.data('data', data);
|
||||
that._forceReflow(data.context);
|
||||
deferred = that._addFinishedDeferreds();
|
||||
that._transition(data.context).done(
|
||||
function () {
|
||||
data.context = $(this);
|
||||
that._trigger('failed', e, data);
|
||||
that._trigger('finished', e, data);
|
||||
deferred.resolve();
|
||||
}
|
||||
);
|
||||
} else {
|
||||
that._trigger('failed', e, data);
|
||||
that._trigger('finished', e, data);
|
||||
that._addFinishedDeferreds().resolve();
|
||||
}
|
||||
},
|
||||
// Callback for upload progress events:
|
||||
progress: function (e, data) {
|
||||
if (e.isDefaultPrevented()) {
|
||||
return false;
|
||||
}
|
||||
var progress = Math.floor(data.loaded / data.total * 100);
|
||||
if (data.context) {
|
||||
data.context.each(function () {
|
||||
$(this).find('.progress')
|
||||
.attr('aria-valuenow', progress)
|
||||
.children().first().css(
|
||||
'width',
|
||||
progress + '%'
|
||||
);
|
||||
});
|
||||
}
|
||||
},
|
||||
// Callback for global upload progress events:
|
||||
progressall: function (e, data) {
|
||||
if (e.isDefaultPrevented()) {
|
||||
return false;
|
||||
}
|
||||
var $this = $(this),
|
||||
progress = Math.floor(data.loaded / data.total * 100),
|
||||
globalProgressNode = $this.find('.fileupload-progress'),
|
||||
extendedProgressNode = globalProgressNode
|
||||
.find('.progress-extended');
|
||||
if (extendedProgressNode.length) {
|
||||
extendedProgressNode.html(
|
||||
($this.data('blueimp-fileupload') || $this.data('fileupload'))
|
||||
._renderExtendedProgress(data)
|
||||
);
|
||||
}
|
||||
globalProgressNode
|
||||
.find('.progress')
|
||||
.attr('aria-valuenow', progress)
|
||||
.children().first().css(
|
||||
'width',
|
||||
progress + '%'
|
||||
);
|
||||
},
|
||||
// Callback for uploads start, equivalent to the global ajaxStart event:
|
||||
start: function (e) {
|
||||
if (e.isDefaultPrevented()) {
|
||||
return false;
|
||||
}
|
||||
var that = $(this).data('blueimp-fileupload') ||
|
||||
$(this).data('fileupload');
|
||||
that._resetFinishedDeferreds();
|
||||
that._transition($(this).find('.fileupload-progress')).done(
|
||||
function () {
|
||||
that._trigger('started', e);
|
||||
}
|
||||
);
|
||||
},
|
||||
// Callback for uploads stop, equivalent to the global ajaxStop event:
|
||||
stop: function (e) {
|
||||
if (e.isDefaultPrevented()) {
|
||||
return false;
|
||||
}
|
||||
var that = $(this).data('blueimp-fileupload') ||
|
||||
$(this).data('fileupload'),
|
||||
deferred = that._addFinishedDeferreds();
|
||||
$.when.apply($, that._getFinishedDeferreds())
|
||||
.done(function () {
|
||||
that._trigger('stopped', e);
|
||||
});
|
||||
that._transition($(this).find('.fileupload-progress')).done(
|
||||
function () {
|
||||
$(this).find('.progress')
|
||||
.attr('aria-valuenow', '0')
|
||||
.children().first().css('width', '0%');
|
||||
$(this).find('.progress-extended').html(' ');
|
||||
deferred.resolve();
|
||||
}
|
||||
);
|
||||
},
|
||||
processstart: function (e) {
|
||||
if (e.isDefaultPrevented()) {
|
||||
return false;
|
||||
}
|
||||
$(this).addClass('fileupload-processing');
|
||||
},
|
||||
processstop: function (e) {
|
||||
if (e.isDefaultPrevented()) {
|
||||
return false;
|
||||
}
|
||||
$(this).removeClass('fileupload-processing');
|
||||
},
|
||||
// Callback for file deletion:
|
||||
destroy: function (e, data) {
|
||||
if (e.isDefaultPrevented()) {
|
||||
return false;
|
||||
}
|
||||
var that = $(this).data('blueimp-fileupload') ||
|
||||
$(this).data('fileupload'),
|
||||
removeNode = function () {
|
||||
that._transition(data.context).done(
|
||||
function () {
|
||||
$(this).remove();
|
||||
that._trigger('destroyed', e, data);
|
||||
}
|
||||
);
|
||||
};
|
||||
if (data.url) {
|
||||
data.dataType = data.dataType || that.options.dataType;
|
||||
$.ajax(data).done(removeNode).fail(function () {
|
||||
that._trigger('destroyfailed', e, data);
|
||||
});
|
||||
} else {
|
||||
removeNode();
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
_resetFinishedDeferreds: function () {
|
||||
this._finishedUploads = [];
|
||||
},
|
||||
|
||||
_addFinishedDeferreds: function (deferred) {
|
||||
if (!deferred) {
|
||||
deferred = $.Deferred();
|
||||
}
|
||||
this._finishedUploads.push(deferred);
|
||||
return deferred;
|
||||
},
|
||||
|
||||
_getFinishedDeferreds: function () {
|
||||
return this._finishedUploads;
|
||||
},
|
||||
|
||||
// Link handler, that allows to download files
|
||||
// by drag & drop of the links to the desktop:
|
||||
_enableDragToDesktop: function () {
|
||||
var link = $(this),
|
||||
url = link.prop('href'),
|
||||
name = link.prop('download'),
|
||||
type = 'application/octet-stream';
|
||||
link.bind('dragstart', function (e) {
|
||||
try {
|
||||
e.originalEvent.dataTransfer.setData(
|
||||
'DownloadURL',
|
||||
[type, name, url].join(':')
|
||||
);
|
||||
} catch (ignore) {}
|
||||
});
|
||||
},
|
||||
|
||||
_formatFileSize: function (bytes) {
|
||||
if (typeof bytes !== 'number') {
|
||||
return '';
|
||||
}
|
||||
if (bytes >= 1000000000) {
|
||||
return (bytes / 1000000000).toFixed(2) + ' GB';
|
||||
}
|
||||
if (bytes >= 1000000) {
|
||||
return (bytes / 1000000).toFixed(2) + ' MB';
|
||||
}
|
||||
return (bytes / 1000).toFixed(2) + ' KB';
|
||||
},
|
||||
|
||||
_formatBitrate: function (bits) {
|
||||
if (typeof bits !== 'number') {
|
||||
return '';
|
||||
}
|
||||
if (bits >= 1000000000) {
|
||||
return (bits / 1000000000).toFixed(2) + ' Gbit/s';
|
||||
}
|
||||
if (bits >= 1000000) {
|
||||
return (bits / 1000000).toFixed(2) + ' Mbit/s';
|
||||
}
|
||||
if (bits >= 1000) {
|
||||
return (bits / 1000).toFixed(2) + ' kbit/s';
|
||||
}
|
||||
return bits.toFixed(2) + ' bit/s';
|
||||
},
|
||||
|
||||
_formatTime: function (seconds) {
|
||||
var date = new Date(seconds * 1000),
|
||||
days = Math.floor(seconds / 86400);
|
||||
days = days ? days + 'd ' : '';
|
||||
return days +
|
||||
('0' + date.getUTCHours()).slice(-2) + ':' +
|
||||
('0' + date.getUTCMinutes()).slice(-2) + ':' +
|
||||
('0' + date.getUTCSeconds()).slice(-2);
|
||||
},
|
||||
|
||||
_formatPercentage: function (floatValue) {
|
||||
return (floatValue * 100).toFixed(2) + ' %';
|
||||
},
|
||||
|
||||
_renderExtendedProgress: function (data) {
|
||||
return this._formatBitrate(data.bitrate) + ' | ' +
|
||||
this._formatTime(
|
||||
(data.total - data.loaded) * 8 / data.bitrate
|
||||
) + ' | ' +
|
||||
this._formatPercentage(
|
||||
data.loaded / data.total
|
||||
) + ' | ' +
|
||||
this._formatFileSize(data.loaded) + ' / ' +
|
||||
this._formatFileSize(data.total);
|
||||
},
|
||||
|
||||
_renderTemplate: function (func, files) {
|
||||
if (!func) {
|
||||
return $();
|
||||
}
|
||||
var result = func({
|
||||
files: files,
|
||||
formatFileSize: this._formatFileSize,
|
||||
options: this.options
|
||||
});
|
||||
if (result instanceof $) {
|
||||
return result;
|
||||
}
|
||||
return $(this.options.templatesContainer).html(result).children();
|
||||
},
|
||||
|
||||
_renderPreviews: function (data) {
|
||||
data.context.find('.preview').each(function (index, elm) {
|
||||
$(elm).append(data.files[index].preview);
|
||||
});
|
||||
},
|
||||
|
||||
_renderUpload: function (files) {
|
||||
return this._renderTemplate(
|
||||
this.options.uploadTemplate,
|
||||
files
|
||||
);
|
||||
},
|
||||
|
||||
_renderDownload: function (files) {
|
||||
return this._renderTemplate(
|
||||
this.options.downloadTemplate,
|
||||
files
|
||||
).find('a[download]').each(this._enableDragToDesktop).end();
|
||||
},
|
||||
|
||||
_startHandler: function (e) {
|
||||
e.preventDefault();
|
||||
var button = $(e.currentTarget),
|
||||
template = button.closest('.template-upload'),
|
||||
data = template.data('data');
|
||||
button.prop('disabled', true);
|
||||
if (data && data.submit) {
|
||||
data.submit();
|
||||
}
|
||||
},
|
||||
|
||||
_cancelHandler: function (e) {
|
||||
e.preventDefault();
|
||||
var template = $(e.currentTarget)
|
||||
.closest('.template-upload,.template-download'),
|
||||
data = template.data('data') || {};
|
||||
data.context = data.context || template;
|
||||
if (data.abort) {
|
||||
data.abort();
|
||||
} else {
|
||||
data.errorThrown = 'abort';
|
||||
this._trigger('fail', e, data);
|
||||
}
|
||||
},
|
||||
|
||||
_deleteHandler: function (e) {
|
||||
e.preventDefault();
|
||||
var button = $(e.currentTarget);
|
||||
this._trigger('destroy', e, $.extend({
|
||||
context: button.closest('.template-download'),
|
||||
type: 'DELETE'
|
||||
}, button.data()));
|
||||
},
|
||||
|
||||
_forceReflow: function (node) {
|
||||
return $.support.transition && node.length &&
|
||||
node[0].offsetWidth;
|
||||
},
|
||||
|
||||
_transition: function (node) {
|
||||
var dfd = $.Deferred();
|
||||
if ($.support.transition && node.hasClass('fade') && node.is(':visible')) {
|
||||
node.bind(
|
||||
$.support.transition.end,
|
||||
function (e) {
|
||||
// Make sure we don't respond to other transitions events
|
||||
// in the container element, e.g. from button elements:
|
||||
if (e.target === node[0]) {
|
||||
node.unbind($.support.transition.end);
|
||||
dfd.resolveWith(node);
|
||||
}
|
||||
}
|
||||
).toggleClass('in');
|
||||
} else {
|
||||
node.toggleClass('in');
|
||||
dfd.resolveWith(node);
|
||||
}
|
||||
return dfd;
|
||||
},
|
||||
|
||||
_initButtonBarEventHandlers: function () {
|
||||
var fileUploadButtonBar = this.element.find('.fileupload-buttonbar'),
|
||||
filesList = this.options.filesContainer;
|
||||
this._on(fileUploadButtonBar.find('.start'), {
|
||||
click: function (e) {
|
||||
e.preventDefault();
|
||||
filesList.find('.start').click();
|
||||
}
|
||||
});
|
||||
this._on(fileUploadButtonBar.find('.cancel'), {
|
||||
click: function (e) {
|
||||
e.preventDefault();
|
||||
filesList.find('.cancel').click();
|
||||
}
|
||||
});
|
||||
this._on(fileUploadButtonBar.find('.delete'), {
|
||||
click: function (e) {
|
||||
e.preventDefault();
|
||||
filesList.find('.toggle:checked')
|
||||
.closest('.template-download')
|
||||
.find('.delete').click();
|
||||
fileUploadButtonBar.find('.toggle')
|
||||
.prop('checked', false);
|
||||
}
|
||||
});
|
||||
this._on(fileUploadButtonBar.find('.toggle'), {
|
||||
change: function (e) {
|
||||
filesList.find('.toggle').prop(
|
||||
'checked',
|
||||
$(e.currentTarget).is(':checked')
|
||||
);
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
_destroyButtonBarEventHandlers: function () {
|
||||
this._off(
|
||||
this.element.find('.fileupload-buttonbar')
|
||||
.find('.start, .cancel, .delete'),
|
||||
'click'
|
||||
);
|
||||
this._off(
|
||||
this.element.find('.fileupload-buttonbar .toggle'),
|
||||
'change.'
|
||||
);
|
||||
},
|
||||
|
||||
_initEventHandlers: function () {
|
||||
this._super();
|
||||
this._on(this.options.filesContainer, {
|
||||
'click .start': this._startHandler,
|
||||
'click .cancel': this._cancelHandler,
|
||||
'click .delete': this._deleteHandler
|
||||
});
|
||||
this._initButtonBarEventHandlers();
|
||||
},
|
||||
|
||||
_destroyEventHandlers: function () {
|
||||
this._destroyButtonBarEventHandlers();
|
||||
this._off(this.options.filesContainer, 'click');
|
||||
this._super();
|
||||
},
|
||||
|
||||
_enableFileInputButton: function () {
|
||||
this.element.find('.fileinput-button input')
|
||||
.prop('disabled', false)
|
||||
.parent().removeClass('disabled');
|
||||
},
|
||||
|
||||
_disableFileInputButton: function () {
|
||||
this.element.find('.fileinput-button input')
|
||||
.prop('disabled', true)
|
||||
.parent().addClass('disabled');
|
||||
},
|
||||
|
||||
_initTemplates: function () {
|
||||
var options = this.options;
|
||||
options.templatesContainer = this.document[0].createElement(
|
||||
options.filesContainer.prop('nodeName')
|
||||
);
|
||||
if (tmpl) {
|
||||
if (options.uploadTemplateId) {
|
||||
options.uploadTemplate = tmpl(options.uploadTemplateId);
|
||||
}
|
||||
if (options.downloadTemplateId) {
|
||||
options.downloadTemplate = tmpl(options.downloadTemplateId);
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
_initFilesContainer: function () {
|
||||
var options = this.options;
|
||||
if (options.filesContainer === undefined) {
|
||||
options.filesContainer = this.element.find('.files');
|
||||
} else if (!(options.filesContainer instanceof $)) {
|
||||
options.filesContainer = $(options.filesContainer);
|
||||
}
|
||||
},
|
||||
|
||||
_initSpecialOptions: function () {
|
||||
this._super();
|
||||
this._initFilesContainer();
|
||||
this._initTemplates();
|
||||
},
|
||||
|
||||
_create: function () {
|
||||
this._super();
|
||||
this._resetFinishedDeferreds();
|
||||
if (!$.support.fileInput) {
|
||||
this._disableFileInputButton();
|
||||
}
|
||||
},
|
||||
|
||||
enable: function () {
|
||||
var wasDisabled = false;
|
||||
if (this.options.disabled) {
|
||||
wasDisabled = true;
|
||||
}
|
||||
this._super();
|
||||
if (wasDisabled) {
|
||||
this.element.find('input, button').prop('disabled', false);
|
||||
this._enableFileInputButton();
|
||||
}
|
||||
},
|
||||
|
||||
disable: function () {
|
||||
if (!this.options.disabled) {
|
||||
this.element.find('input, button').prop('disabled', true);
|
||||
this._disableFileInputButton();
|
||||
}
|
||||
this._super();
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
}));
|
||||
@@ -0,0 +1,214 @@
|
||||
/*
|
||||
* jQuery Iframe Transport Plugin 1.8.2
|
||||
* https://github.com/blueimp/jQuery-File-Upload
|
||||
*
|
||||
* Copyright 2011, Sebastian Tschan
|
||||
* https://blueimp.net
|
||||
*
|
||||
* Licensed under the MIT license:
|
||||
* http://www.opensource.org/licenses/MIT
|
||||
*/
|
||||
|
||||
/* global define, window, document */
|
||||
|
||||
(function (factory) {
|
||||
'use strict';
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// Register as an anonymous AMD module:
|
||||
define(['jquery'], factory);
|
||||
} else {
|
||||
// Browser globals:
|
||||
factory(window.jQuery);
|
||||
}
|
||||
}(function ($) {
|
||||
'use strict';
|
||||
|
||||
// Helper variable to create unique names for the transport iframes:
|
||||
var counter = 0;
|
||||
|
||||
// The iframe transport accepts four additional options:
|
||||
// options.fileInput: a jQuery collection of file input fields
|
||||
// options.paramName: the parameter name for the file form data,
|
||||
// overrides the name property of the file input field(s),
|
||||
// can be a string or an array of strings.
|
||||
// options.formData: an array of objects with name and value properties,
|
||||
// equivalent to the return data of .serializeArray(), e.g.:
|
||||
// [{name: 'a', value: 1}, {name: 'b', value: 2}]
|
||||
// options.initialIframeSrc: the URL of the initial iframe src,
|
||||
// by default set to "javascript:false;"
|
||||
$.ajaxTransport('iframe', function (options) {
|
||||
if (options.async) {
|
||||
// javascript:false as initial iframe src
|
||||
// prevents warning popups on HTTPS in IE6:
|
||||
/*jshint scripturl: true */
|
||||
var initialIframeSrc = options.initialIframeSrc || 'javascript:false;',
|
||||
/*jshint scripturl: false */
|
||||
form,
|
||||
iframe,
|
||||
addParamChar;
|
||||
return {
|
||||
send: function (_, completeCallback) {
|
||||
form = $('<form style="display:none;"></form>');
|
||||
form.attr('accept-charset', options.formAcceptCharset);
|
||||
addParamChar = /\?/.test(options.url) ? '&' : '?';
|
||||
// XDomainRequest only supports GET and POST:
|
||||
if (options.type === 'DELETE') {
|
||||
options.url = options.url + addParamChar + '_method=DELETE';
|
||||
options.type = 'POST';
|
||||
} else if (options.type === 'PUT') {
|
||||
options.url = options.url + addParamChar + '_method=PUT';
|
||||
options.type = 'POST';
|
||||
} else if (options.type === 'PATCH') {
|
||||
options.url = options.url + addParamChar + '_method=PATCH';
|
||||
options.type = 'POST';
|
||||
}
|
||||
// IE versions below IE8 cannot set the name property of
|
||||
// elements that have already been added to the DOM,
|
||||
// so we set the name along with the iframe HTML markup:
|
||||
counter += 1;
|
||||
iframe = $(
|
||||
'<iframe src="' + initialIframeSrc +
|
||||
'" name="iframe-transport-' + counter + '"></iframe>'
|
||||
).bind('load', function () {
|
||||
var fileInputClones,
|
||||
paramNames = $.isArray(options.paramName) ?
|
||||
options.paramName : [options.paramName];
|
||||
iframe
|
||||
.unbind('load')
|
||||
.bind('load', function () {
|
||||
var response;
|
||||
// Wrap in a try/catch block to catch exceptions thrown
|
||||
// when trying to access cross-domain iframe contents:
|
||||
try {
|
||||
response = iframe.contents();
|
||||
// Google Chrome and Firefox do not throw an
|
||||
// exception when calling iframe.contents() on
|
||||
// cross-domain requests, so we unify the response:
|
||||
if (!response.length || !response[0].firstChild) {
|
||||
throw new Error();
|
||||
}
|
||||
} catch (e) {
|
||||
response = undefined;
|
||||
}
|
||||
// The complete callback returns the
|
||||
// iframe content document as response object:
|
||||
completeCallback(
|
||||
200,
|
||||
'success',
|
||||
{'iframe': response}
|
||||
);
|
||||
// Fix for IE endless progress bar activity bug
|
||||
// (happens on form submits to iframe targets):
|
||||
$('<iframe src="' + initialIframeSrc + '"></iframe>')
|
||||
.appendTo(form);
|
||||
window.setTimeout(function () {
|
||||
// Removing the form in a setTimeout call
|
||||
// allows Chrome's developer tools to display
|
||||
// the response result
|
||||
form.remove();
|
||||
}, 0);
|
||||
});
|
||||
form
|
||||
.prop('target', iframe.prop('name'))
|
||||
.prop('action', options.url)
|
||||
.prop('method', options.type);
|
||||
if (options.formData) {
|
||||
$.each(options.formData, function (index, field) {
|
||||
$('<input type="hidden"/>')
|
||||
.prop('name', field.name)
|
||||
.val(field.value)
|
||||
.appendTo(form);
|
||||
});
|
||||
}
|
||||
if (options.fileInput && options.fileInput.length &&
|
||||
options.type === 'POST') {
|
||||
fileInputClones = options.fileInput.clone();
|
||||
// Insert a clone for each file input field:
|
||||
options.fileInput.after(function (index) {
|
||||
return fileInputClones[index];
|
||||
});
|
||||
if (options.paramName) {
|
||||
options.fileInput.each(function (index) {
|
||||
$(this).prop(
|
||||
'name',
|
||||
paramNames[index] || options.paramName
|
||||
);
|
||||
});
|
||||
}
|
||||
// Appending the file input fields to the hidden form
|
||||
// removes them from their original location:
|
||||
form
|
||||
.append(options.fileInput)
|
||||
.prop('enctype', 'multipart/form-data')
|
||||
// enctype must be set as encoding for IE:
|
||||
.prop('encoding', 'multipart/form-data');
|
||||
// Remove the HTML5 form attribute from the input(s):
|
||||
options.fileInput.removeAttr('form');
|
||||
}
|
||||
form.submit();
|
||||
// Insert the file input fields at their original location
|
||||
// by replacing the clones with the originals:
|
||||
if (fileInputClones && fileInputClones.length) {
|
||||
options.fileInput.each(function (index, input) {
|
||||
var clone = $(fileInputClones[index]);
|
||||
// Restore the original name and form properties:
|
||||
$(input)
|
||||
.prop('name', clone.prop('name'))
|
||||
.attr('form', clone.attr('form'));
|
||||
clone.replaceWith(input);
|
||||
});
|
||||
}
|
||||
});
|
||||
form.append(iframe).appendTo(document.body);
|
||||
},
|
||||
abort: function () {
|
||||
if (iframe) {
|
||||
// javascript:false as iframe src aborts the request
|
||||
// and prevents warning popups on HTTPS in IE6.
|
||||
// concat is used to avoid the "Script URL" JSLint error:
|
||||
iframe
|
||||
.unbind('load')
|
||||
.prop('src', initialIframeSrc);
|
||||
}
|
||||
if (form) {
|
||||
form.remove();
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
});
|
||||
|
||||
// The iframe transport returns the iframe content document as response.
|
||||
// The following adds converters from iframe to text, json, html, xml
|
||||
// and script.
|
||||
// Please note that the Content-Type for JSON responses has to be text/plain
|
||||
// or text/html, if the browser doesn't include application/json in the
|
||||
// Accept header, else IE will show a download dialog.
|
||||
// The Content-Type for XML responses on the other hand has to be always
|
||||
// application/xml or text/xml, so IE properly parses the XML response.
|
||||
// See also
|
||||
// https://github.com/blueimp/jQuery-File-Upload/wiki/Setup#content-type-negotiation
|
||||
$.ajaxSetup({
|
||||
converters: {
|
||||
'iframe text': function (iframe) {
|
||||
return iframe && $(iframe[0].body).text();
|
||||
},
|
||||
'iframe json': function (iframe) {
|
||||
return iframe && $.parseJSON($(iframe[0].body).text());
|
||||
},
|
||||
'iframe html': function (iframe) {
|
||||
return iframe && $(iframe[0].body).html();
|
||||
},
|
||||
'iframe xml': function (iframe) {
|
||||
var xmlDoc = iframe && iframe[0];
|
||||
return xmlDoc && $.isXMLDoc(xmlDoc) ? xmlDoc :
|
||||
$.parseXML((xmlDoc.XMLDocument && xmlDoc.XMLDocument.xml) ||
|
||||
$(xmlDoc.body).html());
|
||||
},
|
||||
'iframe script': function (iframe) {
|
||||
return iframe && $.globalEval($(iframe[0].body).text());
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
}));
|
||||
@@ -0,0 +1,530 @@
|
||||
/*!
|
||||
* jQuery UI Widget 1.10.4+amd
|
||||
* https://github.com/blueimp/jQuery-File-Upload
|
||||
*
|
||||
* Copyright 2014 jQuery Foundation and other contributors
|
||||
* Released under the MIT license.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://api.jqueryui.com/jQuery.widget/
|
||||
*/
|
||||
|
||||
(function (factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
// Register as an anonymous AMD module:
|
||||
define(["jquery"], factory);
|
||||
} else {
|
||||
// Browser globals:
|
||||
factory(jQuery);
|
||||
}
|
||||
}(function( $, undefined ) {
|
||||
|
||||
var uuid = 0,
|
||||
slice = Array.prototype.slice,
|
||||
_cleanData = $.cleanData;
|
||||
$.cleanData = function( elems ) {
|
||||
for ( var i = 0, elem; (elem = elems[i]) != null; i++ ) {
|
||||
try {
|
||||
$( elem ).triggerHandler( "remove" );
|
||||
// http://bugs.jquery.com/ticket/8235
|
||||
} catch( e ) {}
|
||||
}
|
||||
_cleanData( elems );
|
||||
};
|
||||
|
||||
$.widget = function( name, base, prototype ) {
|
||||
var fullName, existingConstructor, constructor, basePrototype,
|
||||
// proxiedPrototype allows the provided prototype to remain unmodified
|
||||
// so that it can be used as a mixin for multiple widgets (#8876)
|
||||
proxiedPrototype = {},
|
||||
namespace = name.split( "." )[ 0 ];
|
||||
|
||||
name = name.split( "." )[ 1 ];
|
||||
fullName = namespace + "-" + name;
|
||||
|
||||
if ( !prototype ) {
|
||||
prototype = base;
|
||||
base = $.Widget;
|
||||
}
|
||||
|
||||
// create selector for plugin
|
||||
$.expr[ ":" ][ fullName.toLowerCase() ] = function( elem ) {
|
||||
return !!$.data( elem, fullName );
|
||||
};
|
||||
|
||||
$[ namespace ] = $[ namespace ] || {};
|
||||
existingConstructor = $[ namespace ][ name ];
|
||||
constructor = $[ namespace ][ name ] = function( options, element ) {
|
||||
// allow instantiation without "new" keyword
|
||||
if ( !this._createWidget ) {
|
||||
return new constructor( options, element );
|
||||
}
|
||||
|
||||
// allow instantiation without initializing for simple inheritance
|
||||
// must use "new" keyword (the code above always passes args)
|
||||
if ( arguments.length ) {
|
||||
this._createWidget( options, element );
|
||||
}
|
||||
};
|
||||
// extend with the existing constructor to carry over any static properties
|
||||
$.extend( constructor, existingConstructor, {
|
||||
version: prototype.version,
|
||||
// copy the object used to create the prototype in case we need to
|
||||
// redefine the widget later
|
||||
_proto: $.extend( {}, prototype ),
|
||||
// track widgets that inherit from this widget in case this widget is
|
||||
// redefined after a widget inherits from it
|
||||
_childConstructors: []
|
||||
});
|
||||
|
||||
basePrototype = new base();
|
||||
// we need to make the options hash a property directly on the new instance
|
||||
// otherwise we'll modify the options hash on the prototype that we're
|
||||
// inheriting from
|
||||
basePrototype.options = $.widget.extend( {}, basePrototype.options );
|
||||
$.each( prototype, function( prop, value ) {
|
||||
if ( !$.isFunction( value ) ) {
|
||||
proxiedPrototype[ prop ] = value;
|
||||
return;
|
||||
}
|
||||
proxiedPrototype[ prop ] = (function() {
|
||||
var _super = function() {
|
||||
return base.prototype[ prop ].apply( this, arguments );
|
||||
},
|
||||
_superApply = function( args ) {
|
||||
return base.prototype[ prop ].apply( this, args );
|
||||
};
|
||||
return function() {
|
||||
var __super = this._super,
|
||||
__superApply = this._superApply,
|
||||
returnValue;
|
||||
|
||||
this._super = _super;
|
||||
this._superApply = _superApply;
|
||||
|
||||
returnValue = value.apply( this, arguments );
|
||||
|
||||
this._super = __super;
|
||||
this._superApply = __superApply;
|
||||
|
||||
return returnValue;
|
||||
};
|
||||
})();
|
||||
});
|
||||
constructor.prototype = $.widget.extend( basePrototype, {
|
||||
// TODO: remove support for widgetEventPrefix
|
||||
// always use the name + a colon as the prefix, e.g., draggable:start
|
||||
// don't prefix for widgets that aren't DOM-based
|
||||
widgetEventPrefix: existingConstructor ? (basePrototype.widgetEventPrefix || name) : name
|
||||
}, proxiedPrototype, {
|
||||
constructor: constructor,
|
||||
namespace: namespace,
|
||||
widgetName: name,
|
||||
widgetFullName: fullName
|
||||
});
|
||||
|
||||
// If this widget is being redefined then we need to find all widgets that
|
||||
// are inheriting from it and redefine all of them so that they inherit from
|
||||
// the new version of this widget. We're essentially trying to replace one
|
||||
// level in the prototype chain.
|
||||
if ( existingConstructor ) {
|
||||
$.each( existingConstructor._childConstructors, function( i, child ) {
|
||||
var childPrototype = child.prototype;
|
||||
|
||||
// redefine the child widget using the same prototype that was
|
||||
// originally used, but inherit from the new version of the base
|
||||
$.widget( childPrototype.namespace + "." + childPrototype.widgetName, constructor, child._proto );
|
||||
});
|
||||
// remove the list of existing child constructors from the old constructor
|
||||
// so the old child constructors can be garbage collected
|
||||
delete existingConstructor._childConstructors;
|
||||
} else {
|
||||
base._childConstructors.push( constructor );
|
||||
}
|
||||
|
||||
$.widget.bridge( name, constructor );
|
||||
};
|
||||
|
||||
$.widget.extend = function( target ) {
|
||||
var input = slice.call( arguments, 1 ),
|
||||
inputIndex = 0,
|
||||
inputLength = input.length,
|
||||
key,
|
||||
value;
|
||||
for ( ; inputIndex < inputLength; inputIndex++ ) {
|
||||
for ( key in input[ inputIndex ] ) {
|
||||
value = input[ inputIndex ][ key ];
|
||||
if ( input[ inputIndex ].hasOwnProperty( key ) && value !== undefined ) {
|
||||
// Clone objects
|
||||
if ( $.isPlainObject( value ) ) {
|
||||
target[ key ] = $.isPlainObject( target[ key ] ) ?
|
||||
$.widget.extend( {}, target[ key ], value ) :
|
||||
// Don't extend strings, arrays, etc. with objects
|
||||
$.widget.extend( {}, value );
|
||||
// Copy everything else by reference
|
||||
} else {
|
||||
target[ key ] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return target;
|
||||
};
|
||||
|
||||
$.widget.bridge = function( name, object ) {
|
||||
var fullName = object.prototype.widgetFullName || name;
|
||||
$.fn[ name ] = function( options ) {
|
||||
var isMethodCall = typeof options === "string",
|
||||
args = slice.call( arguments, 1 ),
|
||||
returnValue = this;
|
||||
|
||||
// allow multiple hashes to be passed on init
|
||||
options = !isMethodCall && args.length ?
|
||||
$.widget.extend.apply( null, [ options ].concat(args) ) :
|
||||
options;
|
||||
|
||||
if ( isMethodCall ) {
|
||||
this.each(function() {
|
||||
var methodValue,
|
||||
instance = $.data( this, fullName );
|
||||
if ( !instance ) {
|
||||
return $.error( "cannot call methods on " + name + " prior to initialization; " +
|
||||
"attempted to call method '" + options + "'" );
|
||||
}
|
||||
if ( !$.isFunction( instance[options] ) || options.charAt( 0 ) === "_" ) {
|
||||
return $.error( "no such method '" + options + "' for " + name + " widget instance" );
|
||||
}
|
||||
methodValue = instance[ options ].apply( instance, args );
|
||||
if ( methodValue !== instance && methodValue !== undefined ) {
|
||||
returnValue = methodValue && methodValue.jquery ?
|
||||
returnValue.pushStack( methodValue.get() ) :
|
||||
methodValue;
|
||||
return false;
|
||||
}
|
||||
});
|
||||
} else {
|
||||
this.each(function() {
|
||||
var instance = $.data( this, fullName );
|
||||
if ( instance ) {
|
||||
instance.option( options || {} )._init();
|
||||
} else {
|
||||
$.data( this, fullName, new object( options, this ) );
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
return returnValue;
|
||||
};
|
||||
};
|
||||
|
||||
$.Widget = function( /* options, element */ ) {};
|
||||
$.Widget._childConstructors = [];
|
||||
|
||||
$.Widget.prototype = {
|
||||
widgetName: "widget",
|
||||
widgetEventPrefix: "",
|
||||
defaultElement: "<div>",
|
||||
options: {
|
||||
disabled: false,
|
||||
|
||||
// callbacks
|
||||
create: null
|
||||
},
|
||||
_createWidget: function( options, element ) {
|
||||
element = $( element || this.defaultElement || this )[ 0 ];
|
||||
this.element = $( element );
|
||||
this.uuid = uuid++;
|
||||
this.eventNamespace = "." + this.widgetName + this.uuid;
|
||||
this.options = $.widget.extend( {},
|
||||
this.options,
|
||||
this._getCreateOptions(),
|
||||
options );
|
||||
|
||||
this.bindings = $();
|
||||
this.hoverable = $();
|
||||
this.focusable = $();
|
||||
|
||||
if ( element !== this ) {
|
||||
$.data( element, this.widgetFullName, this );
|
||||
this._on( true, this.element, {
|
||||
remove: function( event ) {
|
||||
if ( event.target === element ) {
|
||||
this.destroy();
|
||||
}
|
||||
}
|
||||
});
|
||||
this.document = $( element.style ?
|
||||
// element within the document
|
||||
element.ownerDocument :
|
||||
// element is window or document
|
||||
element.document || element );
|
||||
this.window = $( this.document[0].defaultView || this.document[0].parentWindow );
|
||||
}
|
||||
|
||||
this._create();
|
||||
this._trigger( "create", null, this._getCreateEventData() );
|
||||
this._init();
|
||||
},
|
||||
_getCreateOptions: $.noop,
|
||||
_getCreateEventData: $.noop,
|
||||
_create: $.noop,
|
||||
_init: $.noop,
|
||||
|
||||
destroy: function() {
|
||||
this._destroy();
|
||||
// we can probably remove the unbind calls in 2.0
|
||||
// all event bindings should go through this._on()
|
||||
this.element
|
||||
.unbind( this.eventNamespace )
|
||||
// 1.9 BC for #7810
|
||||
// TODO remove dual storage
|
||||
.removeData( this.widgetName )
|
||||
.removeData( this.widgetFullName )
|
||||
// support: jquery <1.6.3
|
||||
// http://bugs.jquery.com/ticket/9413
|
||||
.removeData( $.camelCase( this.widgetFullName ) );
|
||||
this.widget()
|
||||
.unbind( this.eventNamespace )
|
||||
.removeAttr( "aria-disabled" )
|
||||
.removeClass(
|
||||
this.widgetFullName + "-disabled " +
|
||||
"ui-state-disabled" );
|
||||
|
||||
// clean up events and states
|
||||
this.bindings.unbind( this.eventNamespace );
|
||||
this.hoverable.removeClass( "ui-state-hover" );
|
||||
this.focusable.removeClass( "ui-state-focus" );
|
||||
},
|
||||
_destroy: $.noop,
|
||||
|
||||
widget: function() {
|
||||
return this.element;
|
||||
},
|
||||
|
||||
option: function( key, value ) {
|
||||
var options = key,
|
||||
parts,
|
||||
curOption,
|
||||
i;
|
||||
|
||||
if ( arguments.length === 0 ) {
|
||||
// don't return a reference to the internal hash
|
||||
return $.widget.extend( {}, this.options );
|
||||
}
|
||||
|
||||
if ( typeof key === "string" ) {
|
||||
// handle nested keys, e.g., "foo.bar" => { foo: { bar: ___ } }
|
||||
options = {};
|
||||
parts = key.split( "." );
|
||||
key = parts.shift();
|
||||
if ( parts.length ) {
|
||||
curOption = options[ key ] = $.widget.extend( {}, this.options[ key ] );
|
||||
for ( i = 0; i < parts.length - 1; i++ ) {
|
||||
curOption[ parts[ i ] ] = curOption[ parts[ i ] ] || {};
|
||||
curOption = curOption[ parts[ i ] ];
|
||||
}
|
||||
key = parts.pop();
|
||||
if ( arguments.length === 1 ) {
|
||||
return curOption[ key ] === undefined ? null : curOption[ key ];
|
||||
}
|
||||
curOption[ key ] = value;
|
||||
} else {
|
||||
if ( arguments.length === 1 ) {
|
||||
return this.options[ key ] === undefined ? null : this.options[ key ];
|
||||
}
|
||||
options[ key ] = value;
|
||||
}
|
||||
}
|
||||
|
||||
this._setOptions( options );
|
||||
|
||||
return this;
|
||||
},
|
||||
_setOptions: function( options ) {
|
||||
var key;
|
||||
|
||||
for ( key in options ) {
|
||||
this._setOption( key, options[ key ] );
|
||||
}
|
||||
|
||||
return this;
|
||||
},
|
||||
_setOption: function( key, value ) {
|
||||
this.options[ key ] = value;
|
||||
|
||||
if ( key === "disabled" ) {
|
||||
this.widget()
|
||||
.toggleClass( this.widgetFullName + "-disabled ui-state-disabled", !!value )
|
||||
.attr( "aria-disabled", value );
|
||||
this.hoverable.removeClass( "ui-state-hover" );
|
||||
this.focusable.removeClass( "ui-state-focus" );
|
||||
}
|
||||
|
||||
return this;
|
||||
},
|
||||
|
||||
enable: function() {
|
||||
return this._setOption( "disabled", false );
|
||||
},
|
||||
disable: function() {
|
||||
return this._setOption( "disabled", true );
|
||||
},
|
||||
|
||||
_on: function( suppressDisabledCheck, element, handlers ) {
|
||||
var delegateElement,
|
||||
instance = this;
|
||||
|
||||
// no suppressDisabledCheck flag, shuffle arguments
|
||||
if ( typeof suppressDisabledCheck !== "boolean" ) {
|
||||
handlers = element;
|
||||
element = suppressDisabledCheck;
|
||||
suppressDisabledCheck = false;
|
||||
}
|
||||
|
||||
// no element argument, shuffle and use this.element
|
||||
if ( !handlers ) {
|
||||
handlers = element;
|
||||
element = this.element;
|
||||
delegateElement = this.widget();
|
||||
} else {
|
||||
// accept selectors, DOM elements
|
||||
element = delegateElement = $( element );
|
||||
this.bindings = this.bindings.add( element );
|
||||
}
|
||||
|
||||
$.each( handlers, function( event, handler ) {
|
||||
function handlerProxy() {
|
||||
// allow widgets to customize the disabled handling
|
||||
// - disabled as an array instead of boolean
|
||||
// - disabled class as method for disabling individual parts
|
||||
if ( !suppressDisabledCheck &&
|
||||
( instance.options.disabled === true ||
|
||||
$( this ).hasClass( "ui-state-disabled" ) ) ) {
|
||||
return;
|
||||
}
|
||||
return ( typeof handler === "string" ? instance[ handler ] : handler )
|
||||
.apply( instance, arguments );
|
||||
}
|
||||
|
||||
// copy the guid so direct unbinding works
|
||||
if ( typeof handler !== "string" ) {
|
||||
handlerProxy.guid = handler.guid =
|
||||
handler.guid || handlerProxy.guid || $.guid++;
|
||||
}
|
||||
|
||||
var match = event.match( /^(\w+)\s*(.*)$/ ),
|
||||
eventName = match[1] + instance.eventNamespace,
|
||||
selector = match[2];
|
||||
if ( selector ) {
|
||||
delegateElement.delegate( selector, eventName, handlerProxy );
|
||||
} else {
|
||||
element.bind( eventName, handlerProxy );
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
_off: function( element, eventName ) {
|
||||
eventName = (eventName || "").split( " " ).join( this.eventNamespace + " " ) + this.eventNamespace;
|
||||
element.unbind( eventName ).undelegate( eventName );
|
||||
},
|
||||
|
||||
_delay: function( handler, delay ) {
|
||||
function handlerProxy() {
|
||||
return ( typeof handler === "string" ? instance[ handler ] : handler )
|
||||
.apply( instance, arguments );
|
||||
}
|
||||
var instance = this;
|
||||
return setTimeout( handlerProxy, delay || 0 );
|
||||
},
|
||||
|
||||
_hoverable: function( element ) {
|
||||
this.hoverable = this.hoverable.add( element );
|
||||
this._on( element, {
|
||||
mouseenter: function( event ) {
|
||||
$( event.currentTarget ).addClass( "ui-state-hover" );
|
||||
},
|
||||
mouseleave: function( event ) {
|
||||
$( event.currentTarget ).removeClass( "ui-state-hover" );
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
_focusable: function( element ) {
|
||||
this.focusable = this.focusable.add( element );
|
||||
this._on( element, {
|
||||
focusin: function( event ) {
|
||||
$( event.currentTarget ).addClass( "ui-state-focus" );
|
||||
},
|
||||
focusout: function( event ) {
|
||||
$( event.currentTarget ).removeClass( "ui-state-focus" );
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
_trigger: function( type, event, data ) {
|
||||
var prop, orig,
|
||||
callback = this.options[ type ];
|
||||
|
||||
data = data || {};
|
||||
event = $.Event( event );
|
||||
event.type = ( type === this.widgetEventPrefix ?
|
||||
type :
|
||||
this.widgetEventPrefix + type ).toLowerCase();
|
||||
// the original event may come from any element
|
||||
// so we need to reset the target on the new event
|
||||
event.target = this.element[ 0 ];
|
||||
|
||||
// copy original event properties over to the new event
|
||||
orig = event.originalEvent;
|
||||
if ( orig ) {
|
||||
for ( prop in orig ) {
|
||||
if ( !( prop in event ) ) {
|
||||
event[ prop ] = orig[ prop ];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
this.element.trigger( event, data );
|
||||
return !( $.isFunction( callback ) &&
|
||||
callback.apply( this.element[0], [ event ].concat( data ) ) === false ||
|
||||
event.isDefaultPrevented() );
|
||||
}
|
||||
};
|
||||
|
||||
$.each( { show: "fadeIn", hide: "fadeOut" }, function( method, defaultEffect ) {
|
||||
$.Widget.prototype[ "_" + method ] = function( element, options, callback ) {
|
||||
if ( typeof options === "string" ) {
|
||||
options = { effect: options };
|
||||
}
|
||||
var hasOptions,
|
||||
effectName = !options ?
|
||||
method :
|
||||
options === true || typeof options === "number" ?
|
||||
defaultEffect :
|
||||
options.effect || defaultEffect;
|
||||
options = options || {};
|
||||
if ( typeof options === "number" ) {
|
||||
options = { duration: options };
|
||||
}
|
||||
hasOptions = !$.isEmptyObject( options );
|
||||
options.complete = callback;
|
||||
if ( options.delay ) {
|
||||
element.delay( options.delay );
|
||||
}
|
||||
if ( hasOptions && $.effects && $.effects.effect[ effectName ] ) {
|
||||
element[ method ]( options );
|
||||
} else if ( effectName !== method && element[ effectName ] ) {
|
||||
element[ effectName ]( options.duration, options.easing, callback );
|
||||
} else {
|
||||
element.queue(function( next ) {
|
||||
$( this )[ method ]();
|
||||
if ( callback ) {
|
||||
callback.call( element[ 0 ] );
|
||||
}
|
||||
next();
|
||||
});
|
||||
}
|
||||
};
|
||||
});
|
||||
|
||||
}));
|
||||
@@ -0,0 +1,100 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
||||
<html lang="ko">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Script-Type" content="text/javascript">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<title>사진 첨부하기 :: SmartEditor2</title>
|
||||
<style type="text/css">
|
||||
/* NHN Web Standard 1Team JJS 120106 */
|
||||
/* Common */
|
||||
body,p,h1,h2,h3,h4,h5,h6,ul,ol,li,dl,dt,dd,table,th,td,form,fieldset,legend,input,textarea,button,select{margin:0;padding:0}
|
||||
body,input,textarea,select,button,table{font-family:'돋움',Dotum,Helvetica,sans-serif;font-size:12px}
|
||||
img,fieldset{border:0}
|
||||
ul,ol{list-style:none}
|
||||
em,address{font-style:normal}
|
||||
a{text-decoration:none}
|
||||
a:hover,a:active,a:focus{text-decoration:underline}
|
||||
|
||||
/* Contents */
|
||||
.blind{visibility:hidden;position:absolute;line-height:0}
|
||||
#pop_wrap{width:383px}
|
||||
#pop_header{height:26px;padding:14px 0 0 20px;border-bottom:1px solid #ededeb;background:#f4f4f3}
|
||||
.pop_container{padding:11px 20px 0}
|
||||
#pop_footer{margin:21px 20px 0;padding:10px 0 16px;border-top:1px solid #e5e5e5;text-align:center}
|
||||
h1{color:#333;font-size:14px;letter-spacing:-1px}
|
||||
.btn_area{word-spacing:2px}
|
||||
.pop_container .drag_area{overflow:hidden;overflow-y:auto;position:relative;width:341px;height:129px;margin-top:4px;border:1px solid #eceff2}
|
||||
.pop_container .drag_area .bg{display:block;position:absolute;top:0;left:0;width:341px;height:129px;background:#fdfdfd url(../../img/photoQuickPopup/bg_drag_image.png) 0 0 no-repeat}
|
||||
.pop_container .nobg{background:none}
|
||||
.pop_container .bar{color:#e0e0e0}
|
||||
.pop_container .lst_type li{overflow:hidden;position:relative;padding:7px 0 6px 8px;border-bottom:1px solid #f4f4f4;vertical-align:top}
|
||||
.pop_container :root .lst_type li{padding:6px 0 5px 8px}
|
||||
.pop_container .lst_type li span{float:left;color:#222}
|
||||
.pop_container .lst_type li em{float:right;margin-top:1px;padding-right:22px;color:#a1a1a1;font-size:11px}
|
||||
.pop_container .lst_type li a{position:absolute;top:6px;right:5px}
|
||||
.pop_container .dsc{margin-top:6px;color:#666;line-height:18px}
|
||||
.pop_container .dsc_v1{margin-top:12px}
|
||||
.pop_container .dsc em{color:#13b72a}
|
||||
.pop_container2{padding:46px 60px 20px}
|
||||
.pop_container2 .dsc{margin-top:6px;color:#666;line-height:18px}
|
||||
.pop_container2 .dsc strong{color:#13b72a}
|
||||
.upload{margin:0 4px 0 0;_margin:0;padding:6px 0 4px 6px;border:solid 1px #d5d5d5;color:#a1a1a1;font-size:12px;border-right-color:#efefef;border-bottom-color:#efefef;length:300px;}
|
||||
:root .upload{padding:6px 0 2px 6px;}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div id="pop_wrap">
|
||||
<!-- header -->
|
||||
<div id="pop_header">
|
||||
<h1>사진 첨부하기</h1>
|
||||
</div>
|
||||
<!-- //header -->
|
||||
<!-- container -->
|
||||
|
||||
<!-- [D] HTML5인 경우 pop_container 클래스와 하위 HTML 적용
|
||||
그밖의 경우 pop_container2 클래스와 하위 HTML 적용 -->
|
||||
<div id="pop_container2" class="pop_container2">
|
||||
<!-- content -->
|
||||
<form id="editor_upimage" name="editor_upimage" action="FileUploader.php" method="post" enctype="multipart/form-data" onSubmit="return false;">
|
||||
<div id="pop_content2">
|
||||
<input type="file" class="upload" id="uploadInputBox" name="Filedata">
|
||||
<p class="dsc" id="info"><strong>10MB</strong>이하의 이미지 파일만 등록할 수 있습니다.<br>(JPG, GIF, PNG, BMP)</p>
|
||||
</div>
|
||||
</form>
|
||||
<!-- //content -->
|
||||
</div>
|
||||
<div id="pop_container" class="pop_container" style="display:none;">
|
||||
<!-- content -->
|
||||
<div id="pop_content">
|
||||
<p class="dsc"><em id="imageCountTxt">0장</em>/10장 <span class="bar">|</span> <em id="totalSizeTxt">0MB</em>/50MB</p>
|
||||
<!-- [D] 첨부 이미지 여부에 따른 Class 변화
|
||||
첨부 이미지가 있는 경우 : em에 "bg" 클래스 적용 //첨부 이미지가 없는 경우 : em에 "nobg" 클래스 적용 -->
|
||||
|
||||
<div class="drag_area" id="drag_area">
|
||||
<ul class="lst_type" >
|
||||
</ul>
|
||||
<em class="blind">마우스로 드래그해서 이미지를 추가해주세요.</em><span id="guide_text" class="bg"></span>
|
||||
</div>
|
||||
<div style="display:none;" id="divImageList"></div>
|
||||
<p class="dsc dsc_v1"><em>한 장당 10MB, 1회에 50MB까지, 10개</em>의 이미지 파일을<br>등록할 수 있습니다. (JPG, GIF, PNG, BMP)</p>
|
||||
</div>
|
||||
<!-- //content -->
|
||||
</div>
|
||||
|
||||
<!-- //container -->
|
||||
<!-- footer -->
|
||||
<div id="pop_footer">
|
||||
<div class="btn_area">
|
||||
<a href="#"><img src="../../img/photoQuickPopup/btn_confirm.png" width="49" height="28" alt="확인" id="btn_confirm"></a>
|
||||
<a href="#"><img src="../../img/photoQuickPopup/btn_cancel.png" width="48" height="28" alt="취소" id="btn_cancel"></a>
|
||||
</div>
|
||||
</div>
|
||||
<!-- //footer -->
|
||||
</div>
|
||||
<script type="text/javascript" src="jindo.min.js" charset="utf-8"></script>
|
||||
<script type="text/javascript" src="jindo.fileuploader.js" charset="utf-8"></script>
|
||||
<script type="text/javascript" src="attach_photo.js" charset="utf-8"></script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||