function changediv(divid,type){switch(type){case 0:document.getElementById(divid).style.display="none";break;case 1:document.getElementById(divid).style.display="block";break;}}function changeclass(divid,classname){document.getElementById(divid).className=classname;}function showreview(){$("#p_write").click(function(){$("#w_reivews").fadeIn("slow");});$("#pt_write").click(function(){$("#w_reivews").fadeIn("slow");});$("#close").click(function(){$("#w_reivews").fadeOut("slow");});}function showdes(){$("#pf_one").click(function(){$("#pf_one").addClass("pf_son");$("#pf_two").removeClass("pf_son");$("#pf_three").removeClass("pf_son");$("#pft_con").slideUp("fast");$("#pfth_con").slideUp("fast");$("#pfo_con").slideDown("slow");});$("#pf_two").click(function(){$("#pf_two").addClass("pf_son");$("#pf_one").removeClass("pf_son");$("#pf_three").removeClass("pf_son");$("#pfo_con").slideUp("fast");$("#pfth_con").slideUp("fast");$("#pft_con").slideDown("slow");});$("#pf_three").click(function(){$("#pf_three").addClass("pf_son");$("#pf_one").removeClass("pf_son");$("#pf_two").removeClass("pf_son");$("#pfo_con").slideUp("fast");$("#pft_con").slideUp("fast");$("#pfth_con").slideDown("slow");});}function nav(){$("#leftnav > li > h1").click(function(){$("#leftnav > li").find('ul').hide();$("#leftnav > li").find('h1').find('a').removeClass("select");$(this).next().toggle("slow");})}$(nav);function showhelp(){$("#ph_one").click(function(){$("#ph_one").addClass("ph_son");$("#ph_two").removeClass("ph_son");$("#ph_three").removeClass("ph_son");$("#pht_con").slideUp("fast");$("#phth_con").slideUp("fast");$("#pho_con").slideDown("slow");});$("#ph_two").click(function(){$("#ph_two").addClass("ph_son");$("#ph_one").removeClass("ph_son");$("#ph_three").removeClass("ph_son");$("#pho_con").slideUp("fast");$("#phth_con").slideUp("fast");$("#pht_con").slideDown("slow");});$("#ph_three").click(function(){$("#ph_three").addClass("ph_son");$("#ph_one").removeClass("ph_son");$("#ph_two").removeClass("ph_son");$("#pho_con").slideUp("fast");$("#pht_con").slideUp("fast");$("#phth_con").slideDown("slow");});}$(showhelp);$(function size(){$("#size").click(function(){$("#ph_one").addClass("ph_son");$("#ph_three").removeClass("ph_son");$("#ph_two").removeClass("ph_son");$("#phth_con").slideUp("fast");$("#pht_con").slideUp("fast");  $('#pho_con').slideDown("slow"); })});$(function color(){$("#color").click(function(){$("#ph_two").addClass("ph_son");$("#ph_three").removeClass("ph_son");$("#ph_one").removeClass("ph_son");$("#phth_con").slideUp("fast");$("#pho_con").slideUp("fast");  $('#pht_con').slideDown("slow"); })});function show_fun(){$("#fun_one").click(function(){$("#fun_one_con").slideToggle('fast');});$("#fun_three").click(function(){$("#fun_three_con").slideToggle('fast');});  $("#fun_two").click(function(){$("#fun_two_con").slideToggle('fast');})}$(show_fun);

$(showreview);$(showdes);

function navShow(li){
	var navShow=li.getElementsByTagName("div")[0];
	navShow.style.display="block";
	}

function navHide(li){
	var navHide=li.getElementsByTagName("div")[0];
	navHide.style.display="none";
	}
function choose_curr(v){
document.currencies_top.currency.value=v;
document.currencies_top.submit();
} 

function isEmail(str) {   
        var re = /^([a-zA-Z0-9]+[_|\-|\.]?)*[a-zA-Z0-9]+@([a-zA-Z0-9]+[_|\-|\.]?)*[a-zA-Z0-9]+\.[a-zA-Z]{2,3}$/;   
        return re.test(str);   
    } 
	function isEmailSpan(id) {   
        var val = document.getElementById(id);   
        if (!this.isEmail(val.value)) {   
            val.select();   
            var str = "Please enter a valid email address!";   
           	alert(str);  
            return false;   
        } else {    
            return true;   
        }   
    } 
