// SUBMIT
function fncChangeNum() {
    document.frmCart.act.value = 'change_num';
    document.frmCart.submit();
}
function fncOrder() {
    document.frmCart.act.value = 'order';
    document.frmCart.submit();
}
function fncOrderReg() {
    document.frmCart.action = 'https://gt106.secure.ne.jp/~gt106065/store/reg/';
    document.frmCart.act.value = 'reg';
    document.frmCart.submit();
}
//-------------------------------------------------------------------------------------------------
function SelectionCategory(f) {
    url = '?c1=' + eval(f.c1.value);
    document.location.href = url;
}
//-------------------------------------------------------------------------------------------------
var scrj = 1;
function softScrollBack() {
   if(navigator.appName == "Microsoft Internet Explorer" && document.compatMode == "CSS1Compat") {
      var scdist = document.body.parentNode.scrollTop;
   } else {
      var scdist = document.body.scrollTop;
   }
   if(scrj<50 && scdist) {
      scdist = (scdist>2) ? Math.ceil(scdist*.2) : 1;
      scrj++;
      scrollBy(0,-scdist);
      setTimeout("softScrollBack()",30);
   } else {
      scrollTo(0,0);
      scrj = 1;
   }
}
//-------------------------------------------------------------------------------------------------
preloads = new Array('img/minus.gif', 'img/plus.gif');
icoImg   = new Array();
for ( i in preloads ) {
    icoImg[i]     = new Image();
    icoImg[i].src = preloads[i];
}
function submenu(idName) {
    if ( document.getElementById ) {
        childNam = document.getElementById(idName + '_child');
        iconNam  = document.getElementById(idName + '_icon');
    }
    else if ( document.all ) {
        childNam = document.all(idName + '_child');
        iconNam  = document.all(idName + '_icon');
    }
    else if ( document.layers) {
        childNam = document.layers[idName + '_child'];
        iconNam  = document.layers[idName + '_icon'];
    }
    childNam.style.display = (childNam.style.display == 'block') ? 'none' : 'block';
    iconNam.src            = (childNam.style.display == 'block') ? icoImg[0].src : icoImg[1].src;
}
//-------------------------------------------------------------------------------------------------
function study_tab(id) {
    con_nam = new Array();
    ttl_nam = new Array();
    for ( i=1; i<=5; i++ ) {
        if ( document.getElementById ) {
            con_nam[i] = document.getElementById(i + '_con');
            ttl_nam[i] = document.getElementById(i + '_ttl');
        }
        else if ( document.all ) {
            con_nam[i] = document.all(i + '_con');
            ttl_nam[i] = document.all(i + '_ttl');
        }
        else if ( document.layers) {
            con_nam[i] = document.layers[i + '_con'];
            ttl_nam[i] = document.layers[i + '_ttl'];
        }
        ttl_nam[i].style.background = ( i + '_ttl' == id ) ? '#cccc99' : '#eeeecc';
        con_nam[i].style.display    = ( i + '_ttl' == id ) ? 'block' : 'none';
    }
}
//-------------------------------------------------------------------------------------------------
