document.write('

');
document.write('');
function OpenLeftMenu(id) {
if(!document.getElementById(id)) return;
if(id != "MenuCooking") document.getElementById("MenuCooking").style.display = "none";
if(id != "MenuMap") document.getElementById("MenuMap").style.display = "none";
if(id != "MenuWinery") document.getElementById("MenuWinery").style.display = "none";
if(id != "MenuGrape") document.getElementById("MenuGrape").style.display = "none";
var obj = document.getElementById(id);
var icon = document.getElementById("Icon" + id);
if(obj.style.display == "block") {
obj.style.display = "none";
icon.src = "/common/images/icon_close.gif";
} else {
obj.style.display = "block";
//icon.src = "/common/images/icon_open.gif";
}
if(OpenLeftMenu.arguments.length == 2 && OpenLeftMenu.arguments[1] == "init") {
//
} else {
window.location.href = "#";
}
}
function OpenCookingMenu(id) {
var obj = document.getElementById(id);
var icon = document.getElementById("Icon" + id);
if(obj.style.display == "block") {
obj.style.display = "none";
icon.src = "/common/images/icon_close.gif";
} else {
obj.style.display = "block";
icon.src = "/common/images/icon_open.gif";
}
}
function CookingCheckSearch() {
document.menu_form.keyword_text.value = "";
CookingSearch();
}
function CookingSearch() {
if(CookingSearch.arguments.length == 1) {
document.menu_form.page.value = CookingSearch.arguments[0];
} else {
document.menu_form.page.value = "";
}
document.menu_form.name.value = "";
document.menu_form.action = "/search/category/cooking.php";
document.menu_form.submit();
}
function CookingInitialSearch() {
if(CookingInitialSearch.arguments.length == 1) {
document.menu_form.page.value = CookingInitialSearch.arguments[0];
} else {
document.menu_form.page.value = "";
}
document.menu_form.name.value = "";
document.menu_form.action = "";
document.menu_form.submit();
}
function OpenMaterialWindow(type) {
window.open("/search/category/cooking-material.php?type=" + type,"MaterialDetail","height=600 width=800 scrollbars=yes");
}
function AddMaterialDetails(value,type) {
var inp = document.createElement("input");
inp.setAttribute("id",value);
inp.setAttribute("type","hidden");
inp.setAttribute("name","details_" + type + "[]");
inp.setAttribute("value",value);
document.getElementById("MaterialDetails").appendChild(inp);
}
function DelMaterialDetails(value) {
var inp = document.getElementById(value);
document.getElementById("MaterialDetails").removeChild(inp);
}