<?php
$sub_menu = "777200";
include_once('./_common.php');
include_once(AMINA_PATH.'/lib/admin.lib.php');

//스킨타입설정
if($loc == "m") {
	if($sca) {
		$skin_type = 3;
	} else {
		$skin_type = 2;
	}
} else {
	if($sca) { 
		$skin_type = 1;
	} else {
		$skin_type = 0;
	}
}

//관리모드
if($loc == "ma" && $id) {
	if($type == "func") {
	    sql_query(" delete from {$g5['amina']} where id = '$id' ");
	} else {
	    sql_query(" delete from {$g5['amina_skin']} where id = '$id' ");
	}
	alert("설정값을 삭제했습니다.", AMINA_URL."/admin.dashboard.php?bo_table=".$bo_table."&loc=".$loc);
}

//삭제시
if($mode == "d" && $id) {
    sql_query(" delete from {$g5['amina_skin']} where id = '$id' ");
	alert("설정값을 삭제했습니다.", AMINA_URL."/admin.dashboard.php?bo_table=".$bo_table."&loc=".$loc);
}

//배열키값 생성
$amina_keys = array();
$amina_keys = array_keys($amina);

// 기능저장
if($loc == "func") {
	include(AMINA_PATH.'/admin.update.func.php');
} else {
	include(AMINA_PATH.'/admin.update.skin.php');
}

alert("설정값을 저장했습니다.", AMINA_URL."/admin.dashboard.php?bo_table=".$bo_table."&loc=".$loc."&sca=".urlencode($sca));

?>