2022-09-17 20:50:50 +09:00
|
|
|
<?php
|
2024-09-19 20:36:07 +09:00
|
|
|
if (!defined('_GNUBOARD_'))
|
|
|
|
|
exit; // 개별 페이지 접근 불가
|
2024-10-01 02:01:37 +09:00
|
|
|
|
2024-09-19 21:03:48 +09:00
|
|
|
check_site_auth();
|
2022-09-17 20:50:50 +09:00
|
|
|
|
2024-10-01 02:01:37 +09:00
|
|
|
if (!defined('G5_IS_ADMIN') && defined('G5_THEME_PATH') && file_exists(G5_THEME_PATH . "/head.sub.php")) {
|
|
|
|
|
include_once G5_THEME_PATH . '/head.sub.php';
|
|
|
|
|
return;
|
|
|
|
|
}
|
2022-09-17 20:50:50 +09:00
|
|
|
|
|
|
|
|
if (!isset($g5['title'])) {
|
2024-09-19 20:36:07 +09:00
|
|
|
$g5['title'] = $config['cf_title'];
|
|
|
|
|
$g5_head_title = $g5['title'];
|
|
|
|
|
} else {
|
|
|
|
|
$g5_head_title = $g5['title']; // 상태바에 표시될 제목
|
|
|
|
|
$g5_head_title .= " | " . $config['cf_title'];
|
2022-09-17 20:50:50 +09:00
|
|
|
}
|
|
|
|
|
|
2024-09-22 11:01:55 +09:00
|
|
|
$g5['title'] = strip_tags(get_text($g5['title']));
|
|
|
|
|
$g5_head_title = strip_tags(get_text($g5_head_title));
|
2024-09-19 21:03:48 +09:00
|
|
|
|
2022-09-17 20:50:50 +09:00
|
|
|
$g5['lo_location'] = addslashes($g5['title']);
|
2024-09-19 21:03:48 +09:00
|
|
|
|
|
|
|
|
if (!$g5['lo_location']) {
|
2024-09-19 20:36:07 +09:00
|
|
|
$g5['lo_location'] = addslashes(clean_xss_tags($_SERVER['REQUEST_URI']));
|
2024-09-19 21:03:48 +09:00
|
|
|
}
|
|
|
|
|
|
2022-09-17 20:50:50 +09:00
|
|
|
$g5['lo_url'] = addslashes(clean_xss_tags($_SERVER['REQUEST_URI']));
|
2024-09-19 21:03:48 +09:00
|
|
|
|
|
|
|
|
if (strstr($g5['lo_url'], '/' . G5_ADMIN_DIR . '/') || $is_admin == 'super') {
|
2024-09-19 20:36:07 +09:00
|
|
|
$g5['lo_url'] = '';
|
2024-09-19 21:03:48 +09:00
|
|
|
}
|
2022-09-17 20:50:50 +09:00
|
|
|
|
|
|
|
|
$is_page_login = (strstr($_SERVER["REQUEST_URI"], 'login') == "") ? false : true;
|
|
|
|
|
|
2024-09-19 20:36:07 +09:00
|
|
|
if (defined('_INDEX_')) {
|
|
|
|
|
echo "<script>if(parent && parent!=this) location.href='./main.php';</script>";
|
2024-09-19 21:03:48 +09:00
|
|
|
}
|
2024-09-19 20:36:07 +09:00
|
|
|
|
2024-09-19 21:03:48 +09:00
|
|
|
$html_class = $is_page_login ? "login" : "";
|
|
|
|
|
$html_class .= $_COOKIE['header_close'] == 'close' ? " close-header" : "";
|
2024-10-01 02:01:37 +09:00
|
|
|
?><!DOCTYPE html>
|
2024-09-19 21:03:48 +09:00
|
|
|
<html lang="ko" class='<?= $html_class ?>'>
|
|
|
|
|
<head>
|
|
|
|
|
<meta charset="utf-8">
|
|
|
|
|
<meta name="mobile-web-app-capable" content="yes">
|
|
|
|
|
<meta name="apple-mobile-web-app-capable" content="yes">
|
|
|
|
|
<?php
|
|
|
|
|
if (G5_IS_MOBILE) {
|
|
|
|
|
echo '<meta name="viewport" content="width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no">' . PHP_EOL;
|
|
|
|
|
echo '<meta name="HandheldFriendly" content="true">' . PHP_EOL;
|
|
|
|
|
echo '<meta name="format-detection" content="telephone=no">' . PHP_EOL;
|
|
|
|
|
} else {
|
|
|
|
|
echo '<meta http-equiv="imagetoolbar" content="no">' . PHP_EOL;
|
|
|
|
|
echo '<meta http-equiv="X-UA-Compatible" content="IE=Edge">' . PHP_EOL;
|
|
|
|
|
}
|
2024-09-19 20:36:07 +09:00
|
|
|
|
2024-09-19 21:03:48 +09:00
|
|
|
if ($config['cf_add_meta']) {
|
|
|
|
|
echo $config['cf_add_meta'] . PHP_EOL;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if ($config['cf_site_img']) { ?>
|
|
|
|
|
<link rel="image_src" href="<?= $config['cf_site_img'] ?>" />
|
|
|
|
|
<?php } ?>
|
|
|
|
|
<meta name="description" content="<?= $config['cf_site_descript'] ?>" />
|
|
|
|
|
<meta name="twitter:card" content="summary" />
|
|
|
|
|
<meta name="twitter:url" content="<?= G5_URL ?>" />
|
|
|
|
|
<meta name="twitter:title" content="<?php echo $g5_head_title; ?>" />
|
|
|
|
|
<meta name="twitter:description" content="<?= $config['cf_site_descript'] ?>" />
|
2024-09-19 20:36:07 +09:00
|
|
|
|
2024-09-19 21:03:48 +09:00
|
|
|
<?php if ($config['cf_site_img']) { ?>
|
|
|
|
|
<meta name="twitter:image" content="<?= $config['cf_site_img'] ?>" />
|
|
|
|
|
<?php } ?>
|
2024-09-19 20:36:07 +09:00
|
|
|
|
2024-09-19 21:03:48 +09:00
|
|
|
<title><?php echo $g5_head_title; ?></title>
|
|
|
|
|
<link
|
|
|
|
|
href="https://fonts.googleapis.com/icon?family=Material+Icons|Material+Icons+Outlined|Material+Icons+Two+Tone|Material+Icons+Round|Material+Icons+Sharp"
|
|
|
|
|
rel="stylesheet">
|
|
|
|
|
<?php
|
2024-09-22 13:51:59 +09:00
|
|
|
include_once __DIR__ . "/_extra_font.php";
|
|
|
|
|
|
2024-09-19 21:03:48 +09:00
|
|
|
if (defined('G5_IS_ADMIN')) {
|
2024-09-19 21:06:35 +09:00
|
|
|
echo get_embed_file("css", G5_ADMIN_PATH . '/css/admin.css') . PHP_EOL;
|
|
|
|
|
echo get_embed_file("css", G5_ADMIN_PATH . '/css/admin.layout.css') . PHP_EOL;
|
|
|
|
|
echo get_embed_file("css", G5_ADMIN_PATH . '/css/amberstone.cp.css') . PHP_EOL;
|
2024-09-19 21:03:48 +09:00
|
|
|
} else {
|
2024-09-19 21:08:10 +09:00
|
|
|
if (defined('G5_THEME_PATH') && file_exists(G5_THEME_PATH . "/css/default.css")) {
|
|
|
|
|
echo '<link rel="stylesheet" href="' . G5_THEME_CSS_URL . '/default.css" type="text/css">' . PHP_EOL;
|
|
|
|
|
} else {
|
|
|
|
|
echo '<link rel="stylesheet" href="' . G5_CSS_URL . '/default.css" type="text/css">' . PHP_EOL;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (defined('G5_THEME_PATH') && file_exists(G5_THEME_PATH . "/css/style.css")) {
|
|
|
|
|
echo '<link rel="stylesheet" href="' . G5_THEME_CSS_URL . '/style.css" type="text/css">' . PHP_EOL;
|
|
|
|
|
} else {
|
|
|
|
|
echo '<link rel="stylesheet" href="' . G5_CSS_URL . '/style.css" type="text/css">' . PHP_EOL;
|
|
|
|
|
}
|
|
|
|
|
|
2024-09-19 21:03:48 +09:00
|
|
|
echo '<link rel="stylesheet" href="' . G5_DATA_URL . '/css/_design.config.css?v=' . $config['cf_css_version'] . '" type="text/css" />';
|
|
|
|
|
}
|
|
|
|
|
?>
|
|
|
|
|
<?php if ($config['cf_favicon']) { ?>
|
|
|
|
|
<link rel="shortcut icon" href="<?= $config['cf_favicon'] ?>" type="image/x-icon">
|
|
|
|
|
<link rel="icon" href="<?= $config['cf_favicon'] ?>" type="image/x-icon">
|
2024-09-19 20:36:07 +09:00
|
|
|
<?php } ?>
|
2024-09-19 21:03:48 +09:00
|
|
|
<script>
|
|
|
|
|
<?php if ($config['cf_use_http']) { ?>
|
|
|
|
|
if (window.location.protocol == "https:")
|
|
|
|
|
location.href = location.href.replace(/^https:/, 'http:')
|
|
|
|
|
<?php } ?>
|
|
|
|
|
var g5_url = "<?php echo G5_URL ?>";
|
|
|
|
|
var g5_bbs_url = "<?php echo G5_BBS_URL ?>";
|
|
|
|
|
var g5_is_member = "<?php echo isset($is_member) ? $is_member : ''; ?>";
|
|
|
|
|
var g5_is_admin = "<?php echo isset($is_admin) ? $is_admin : ''; ?>";
|
|
|
|
|
var g5_is_mobile = "<?php echo G5_IS_MOBILE ?>";
|
|
|
|
|
var g5_bo_table = "<?php echo isset($bo_table) ? $bo_table : ''; ?>";
|
|
|
|
|
var g5_sca = "<?php echo isset($sca) ? $sca : ''; ?>";
|
|
|
|
|
var g5_editor = "<?php echo ($config['cf_editor'] && $board['bo_use_dhtml_editor']) ? $config['cf_editor'] : ''; ?>";
|
|
|
|
|
var g5_cookie_domain = "<?php echo G5_COOKIE_DOMAIN ?>";
|
|
|
|
|
<?php if (defined('G5_IS_ADMIN')) { ?>
|
2024-09-19 20:36:07 +09:00
|
|
|
var g5_admin_url = "<?php echo G5_ADMIN_URL; ?>";
|
2024-09-19 21:03:48 +09:00
|
|
|
<?php } ?>
|
|
|
|
|
</script>
|
|
|
|
|
<?php if (defined('G5_IS_ADMIN')) { ?>
|
|
|
|
|
<script src="<?php echo G5_JS_URL ?>/jquery-1.8.3.min.js"></script>
|
|
|
|
|
<script src="<?php echo G5_ADMIN_URL ?>/js/amberstone.cp.js"></script>
|
|
|
|
|
<?php } else { ?>
|
|
|
|
|
<script src="<?php echo G5_JS_URL ?>/jquery-1.12.3.min.js"></script>
|
|
|
|
|
<?php } ?>
|
2024-09-19 21:06:35 +09:00
|
|
|
<script src="<?php echo G5_JS_URL ?>/amberstone.js"></script>
|
2024-09-19 21:03:48 +09:00
|
|
|
<script src="<?php echo G5_JS_URL ?>/jquery.cookie.js"></script>
|
|
|
|
|
<script src="<?php echo G5_JS_URL ?>/jquery.rwdImageMaps.js"></script>
|
|
|
|
|
<script src="<?php echo G5_JS_URL ?>/common.js"></script>
|
|
|
|
|
<script src="<?php echo G5_JS_URL ?>/wrest.js?ver=<?php echo G5_JS_VER; ?>"></script>
|
|
|
|
|
<?php
|
|
|
|
|
if (G5_IS_MOBILE) {
|
|
|
|
|
echo '<script src="' . G5_JS_URL . '/modernizr.custom.70111.js"></script>' . PHP_EOL; // overflow scroll 감지
|
|
|
|
|
}
|
|
|
|
|
if (!defined('G5_IS_ADMIN'))
|
|
|
|
|
echo $config['cf_add_script'];
|
|
|
|
|
?>
|
|
|
|
|
<script>
|
|
|
|
|
if (!parent || parent == this) $('html').addClass('single');
|
|
|
|
|
</script>
|
|
|
|
|
<?php if ($config['cf_cursor']) { ?>
|
|
|
|
|
<style>
|
|
|
|
|
* {
|
|
|
|
|
cursor: url(<?= $config['cf_cursor'] ?>) 0 0, auto;
|
|
|
|
|
}
|
|
|
|
|
</style>
|
2024-09-19 20:36:07 +09:00
|
|
|
<?php } ?>
|
2024-09-19 21:03:48 +09:00
|
|
|
</head>
|
|
|
|
|
<body>
|