var svf="";
var svi="";
var svap="";
function swap(id){ // イメージスワップ(ＩＤ)
  var elm = document.getElementById(id);
  if(elm){
    svf=elm.src;
    if(svf.substring(svf.length-6,svf.length)=="ac.gif"){svi=""; return;}
    elm.src=svf.substring(0,svf.length-4)+"ac.gif"; svi=id;
  }
}
function swapOver(id, imgf){ //イメージスワップ(ＩＤ、イメージファイル）
  var elm = document.getElementById(id); if(elm){svf=elm.src; elm.src=imgf; svi=id;}
}
function swapOut(){ //イメージスワップ戻し
  if(svi!=""){
    var elm=document.getElementById(svi);
    if(elm){
      elm.src=svf; svi="";
    }
  }
}
function rest(id){ //イメージリセット(ＩＤ)
  var elm = document.getElementById(id);
  if(elm){
    svf=elm.src;
    if(svf.substring(svf.length-6,svf.length)!="ac.gif"){svi=""; return;}
    elm.src=svf.substring(0,svf.length-6)+".gif";
  }
}
function menuD(n, op, grp){ //詳細ページ右ブロックインターフェイス
  if(n==1){window.open(""+op, "", "width=800,height=600");}
  if(n==2){svi=""; rest("btn03"); loadPh('/products/Detail'+grp+'.php?'+op,'ProDetailRight');}
  if(n==3){svi=""; rest("btn02"); loadPh('/A07SS/php/pictPrint.php?'+op,'ProDetailRight');}
}
function shoplist(){ //ショップリストインターフェイス
  var n1 = document.pref.brd.selectedIndex;
  var c1 = document.pref.brd.options[n1].value;
  var n2 = document.pref.sel.selectedIndex;
  var c2 = document.pref.sel.options[n2].value;
  if(c1!=""){loadPh("/support/shopinq.php?"+c1+"+"+c2+"+1", "ShopList");}
}
function shoplist2(n1){ //ショップリストインターフェイス
  var c1 = n1;
  var n2 = document.pref.sel.selectedIndex;
  var c2 = document.pref.sel.options[n2].value;
  if(c1!=""){loadPh("/support/shopinq.php?"+c1+"+"+c2+"+1", "ShopList");}
}
//
function map(x){ // 地図用ウィンドオープン
  window.open('/corp/map.html?'+x, '', 'width=520,height=350');
}
//
function wopen2(x, wi, hi){ // エコノミーウィンドウ・縦バー付(URL,Width,Height)
    var p3 = 'width='+wi+',height='+hi+',scrollbars=yes' ;
    window.open(x, "", p3 );
}
//
function wopen1(x, wi, hi){ // エコノミーウィンドウのオープン parameter( x:URL, wi:Width, hi:Height )
    var p3 = "width=" + wi + ",height=" + hi;
    window.open(x, "", p3 );
}
//
function showDt(hin, grp, tp){ // 詳細画面オープンインターフェイス
  var url="";
  if(grp=="basketball"){url="/basketball/products/DetailG.html?"+hin;
  }else{if(grp=="walking"){url="/walking/products/Detail_bc.html?"+hin;
  }else{if(grp=="running"){url="/running/products/Detail"+tp+".html?"+hin;
  }else{url="/products/Detail"+tp+".html?"+hin;}}}
  wopen2(url, 760, 700);
}
//

