답변 3개
/common.php 파일에 이미 정의된 변수라서,
스킨에 별도로 정의되어 있는 걸 제거하면, 자동으로 인식할 겁니다.
답변에 대한 댓글 1개
댓글을 작성하려면 로그인이 필요합니다.
해당 변수는 common.php에서 정의하는데
//============================================================================== // 스킨경로 //------------------------------------------------------------------------------ if (G5_IS_MOBILE) { $board_skin_path = get_skin_path('board', $board['bo_mobile_skin']); ... $faq_skin_url = get_skin_url('faq', $config['cf_mobile_faq_skin']); } else { $board_skin_path = get_skin_path('board', $board['bo_skin']); ... $faq_skin_url = get_skin_url('faq', $config['cf_faq_skin']); }
처리하는 함수는
lib/common.lib.php에
// 스킨 path function get_skin_path($dir, $skin) { global $config;
if(preg_match('#^theme/(.+)$#', $skin, $match)) { // 테마에 포함된 스킨이라면 $theme_path = ''; $cf_theme = trim($config['cf_theme']);
$theme_path = G5_PATH.'/'.G5_THEME_DIR.'/'.$cf_theme; if(G5_IS_MOBILE) { $skin_path = $theme_path.'/'.G5_MOBILE_DIR.'/'.G5_SKIN_DIR.'/'.$dir.'/'.$match[1]; if(!is_dir($skin_path)) $skin_path = $theme_path.'/'.G5_SKIN_DIR.'/'.$dir.'/'.$match[1]; } else { $skin_path = $theme_path.'/'.G5_SKIN_DIR.'/'.$dir.'/'.$match[1]; } } else { if(G5_IS_MOBILE) $skin_path = G5_MOBILE_PATH.'/'.G5_SKIN_DIR.'/'.$dir.'/'.$skin; else $skin_path = G5_SKIN_PATH.'/'.$dir.'/'.$skin; }
return $skin_path; }
// 스킨 url function get_skin_url($dir, $skin) { $skin_path = get_skin_path($dir, $skin);
return str_replace(G5_PATH, G5_URL, $skin_path); }
내용 참고하세요.
답변에 대한 댓글 1개
댓글을 작성하려면 로그인이 필요합니다.
답변을 작성하려면 로그인이 필요합니다.
로그인