/***********************************************
* AnyLink Drop Down Menu- ?Dynamic Drive (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for full source code
***********************************************/

//Contents for menu 1
var menu1=new Array()
menu1[0]='<a href="main.php?module=catalog&catID=61&ParcatID=0&showall=1">CD/DVD/DVDRW/Blu-ray</a>'
menu1[1]='<a href="main.php?module=catalog&catID=88">Chassis</a>'
menu1[2]='<a href="main.php?module=catalog&catID=4">CPU (Processors)</a>'
menu1[3]='<a href="main.php?module=catalog&catID=648">Floppy Drives</a>'
menu1[4]='<a href="main.php?module=catalog&catID=5">Hard Drives</a>'
menu1[5]='<a href="main.php?module=catalog&catID=24">Keyboard/Mouse</a>'
menu1[6]='<a href="main.php?module=catalog&catID=3">Memory (RAM)</a>'
menu1[7]='<a href="main.php?module=catalog&catID=150">Memory (Flash)</a>'
menu1[8]='<a href="main.php?module=catalog&catID=857">Modems</a>'
menu1[9]='<a href="main.php?module=catalog&catID=6">Monitors</a>'
menu1[10]='<a href="main.php?module=catalog&catID=2">MotherBoards</a>'
menu1[11]='<a href="main.php?module=catalog&catID=93">Power Supplies</a>'
menu1[12]='<a href="main.php?module=catalog&catID=180">Sound Cards</a>'
menu1[13]='<a href="main.php?module=catalog&catID=12">Video Display Cards</a>'

var menu2=new Array()
// menu2[0]='<a href="main.php?module=page&name=D2A">D2A System</a>'
menu2[0]='<a href="DIY/pre_config.php?user=HO">Complete Assembled</a>'
menu2[1]='<a href="DIY/notebookpricerange.php?to=800">Notebook</a>'
menu2[2]='<a href="main.php?module=catalog&catID=175&ParcatID=0&showall=1">Server</a>'
menu2[3]='<a href="main.php?module=catalog&catID=92&ParcatID=0&showall=1">Barebone</a>'
menu2[4]='<a href="main.php?module=configlist">Configurator</a>'
menu2[5]='<a href="main.php?module=catalog&catID=610">System Acc.</a>'

var menu3=new Array()
menu3[0]='<a href="main.php?module=catalog&catID=8">Printer</a>'
menu3[1]='<a href="main.php?module=catalog&catID=636">Projector</a>'
menu3[2]='<a href="main.php?module=catalog&catID=364">Scanner</a>'
menu3[3]='<a href="main.php?module=catalog&catID=409">Game Controller</a>'
menu3[4]='<a href="main.php?module=catalog&catID=1169">Headset</a>'
menu3[5]='<a href="main.php?module=catalog&catID=1033">Remote Control</a>'
menu3[6]='<a href="main.php?module=catalog&catID=192">Speaker</a>'
menu3[7]='<a href="main.php?module=catalog&catID=27">Tablet</a>'
menu3[8]='<a href="main.php?module=catalog&catID=162">UPS</a>'

var menu4=new Array()
menu4[0]='<a href="main.php?module=catalog&catID=1546&ParcatID=0&showall=1">Access Points/Bridges</a>'
menu4[1]='<a href="main.php?module=catalog&catID=125">Hubs/Switches</a>'
menu4[2]='<a href="main.php?module=catalog&catID=45">Network Adapters</a>'
menu4[3]='<a href="main.php?module=catalog&catID=124">Print Servers</a>'
menu4[4]='<a href="main.php?module=catalog&catID=44">Routers</a>'
menu4[5]='<a href="main.php?module=catalog&catID=138&ParcatID=0&showall=1">KVM</a>'
menu4[6]='<a href="main.php?module=catalog&catID=662">Networking Acc.</a>'

var menu5=new Array()
menu5[0]='<a href="main.php?module=catalog&catID=1094">AntiVirus</a>'
menu5[1]='<a href="main.php?module=catalog&catID=1125">Graphics</a>'
menu5[2]='<a href="main.php?module=catalog&catID=1120">Internet Security</a>'
menu5[3]='<a href="main.php?module=catalog&catID=1098">Office</a>'
menu5[4]='<a href="main.php?module=catalog&catID=1203">OS</a>'
menu5[5]='<a href="main.php?module=catalog&catID=1097">Utilities</a>'

var menu6=new Array()
menu6[0]='<a href="main.php?module=catalog&catID=1618">Calculators</a>'
menu6[1]='<a href="main.php?module=catalog&catID=715">Cameras</a>'
menu6[2]='<a href="main.php?module=catalog&catID=1050&ParcatID=64&showall=1">GPS</a>'
menu6[3]='<a href="main.php?module=catalog&catID=1144&ParcatID=0&showall=1">Home Enterainment</a>'
menu6[4]='<a href="main.php?module=catalog&catID=1577">Music Keyboards</a>'
menu6[5]='<a href="main.php?module=catalog&catID=68&ParcatID=64&showall=1">MP3</a>'
menu6[6]='<a href="main.php?module=catalog&catID=142&ParcatID=0&showall=1">PDA</a>'
menu6[7]='<a href="main.php?module=catalog&catID=1136">Photo Frame</a>'
menu6[8]='<a href="main.php?module=catalog&catID=1588">Radio</a>'
menu6[9]='<a href="main.php?module=catalog&catID=731&ParcatID=64&showall=1">Telephony</a>'
menu6[10]='<a href="main.php?module=catalog&catID=736">CE ACC.</a>'

var menu7=new Array()
menu7[0]='<a href="main.php?module=catalog&catID=1334">Media</a>'
menu7[1]='<a href="main.php?module=catalog&catID=793">DVD/CD Case</a>'
menu7[2]='<a href="main.php?module=catalog&catID=626">Ink Cartridge</a>'
menu7[3]='<a href="main.php?module=catalog&catID=1388">Drawer/Tray</a>'
menu7[4]='<a href="main.php?module=catalog&catID=383">Paper</a>'
menu7[5]='<a href="main.php?module=catalog&catID=623">Ribbon</a>'
menu7[6]='<a href="main.php?module=catalog&catID=35">Storage Media</a>'
menu7[7]='<a href="main.php?module=catalog&catID=161">Toner/Drum</a>'
menu7[8]='<a href="main.php?module=catalog&catID=641">Consumable Acc.</a>'

var menu8=new Array()
menu8[0]='<a href="main.php?module=catalog&catID=1233&ParcatID=632&showall=1">Adapters</a>'
menu8[1]='<a href="main.php?module=catalog&catID=1223&ParcatID=0&showall=1">Batteries</a>'
menu8[2]='<a href="main.php?module=catalog&catID=34&ParcatID=0&showall=1">Cables</a>'
menu8[3]='<a href="main.php?module=catalog&catID=646">Card Readers</a>'
menu8[4]='<a href="main.php?module=catalog&catID=1406">CD/DVD Cleanser</a>'
menu8[5]='<a href="main.php?module=catalog&catID=1240&ParcatID=632&showall=1">Converters</a>'
menu8[6]='<a href="main.php?module=catalog&catID=366&ParcatID=632&showall=1">Cooling Devices</a>'
menu8[7]='<a href="main.php?module=catalog&catID=155&ParcatID=0&showall=1">Enclosurers</a>'
menu8[8]='<a href="main.php?module=catalog&catID=1590">Accessories</a>'

var menu9=new Array()
menu9[0]='<a href="weeklyspecial.php">Weekly Specials</a>'
menu9[1]='<a href="combo_deal.php">Combo Deal</a>'
menu9[2]='<a href="main.php?module=clearance"><b><font color=red>Clearance</font></b></a>'

var menu10=new Array()
menu10[0]='<a href="main.php?module=mirdisplay">Mail In Rebate</a>'
menu10[1]='<a href="main.php?module=irdisplay">Instant Rebate</a>'
menu10[2]='<a href="main.php?module=archivedrebates">Archived Rebates</a>'

var menuwidth='167px' //default menu width
var menubgcolor='lightyellow'  //menu bgcolor
var disappeardelay1=0  //menu disappear speed onMouseout (in miliseconds)
var hidemenu_onclick="yes" //hide menu when user clicks within menu?

/////No further editting needed

var ie5=(navigator.appName == "Microsoft Internet Explorer")
var ie4=document.all
var ns6=document.getElementById&&!document.all

if (ie5)
document.write('<div id="iframediv"><iframe src="blank.php" style="position:absolute;top:0px;left:0px;width:400px;height:300px; display: none;" id="myMenuIFrame1" frameborder="0"></iframe ></div><div style="z-index: 101" id="dropmenudiv" style="visibility:hidden;width:'+menuwidth+';background-color:'+menubgcolor+'" onMouseover="clearhidemenu()" onMouseout="dynamichide1(event)"></div>')
if (ie4||ns6)
document.write('<div id="dropmenudiv" style="visibility:hidden;width:'+menuwidth+';background-color:'+menubgcolor+'" onMouseover="clearhidemenu()" onMouseout="dynamichide1(event)"></div>')


function getposOffset(what, offsettype){
var totaloffset=(offsettype=="left")? what.offsetLeft : what.offsetTop;
var parentEl=what.offsetParent;
while (parentEl!=null){
totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft : totaloffset+parentEl.offsetTop;
parentEl=parentEl.offsetParent;
}
return totaloffset;
}


function showhide(obj, e, visible, hidden, menuwidth){
if (ie4||ns6)
dropmenuobj.style.left=dropmenuobj.style.top="-500px"
if (menuwidth!=""){
dropmenuobj.widthobj=dropmenuobj.style
dropmenuobj.widthobj.width=menuwidth
}
if (e.type=="click" && obj.visibility==hidden || e.type=="mouseover")
obj.visibility=visible
else if (e.type=="click")
{
	hideiframe()
obj.visibility=hidden
}
}

function iecompattest(){
return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
}

function clearbrowseredge(obj, whichedge){
var edgeoffset=0
if (whichedge=="rightedge"){
var windowedge=ie4 && !window.opera? iecompattest().scrollLeft+iecompattest().clientWidth-15 : window.pageXOffset+window.innerWidth-15
dropmenuobj.contentmeasure=dropmenuobj.offsetWidth
if (windowedge-dropmenuobj.x < dropmenuobj.contentmeasure)
edgeoffset=dropmenuobj.contentmeasure-obj.offsetWidth
}
else{
var topedge=ie4 && !window.opera? iecompattest().scrollTop : window.pageYOffset
var windowedge=ie4 && !window.opera? iecompattest().scrollTop+iecompattest().clientHeight-15 : window.pageYOffset+window.innerHeight-18
dropmenuobj.contentmeasure=dropmenuobj.offsetHeight
if (windowedge-dropmenuobj.y < dropmenuobj.contentmeasure){ //move up?
edgeoffset=dropmenuobj.contentmeasure+obj.offsetHeight
if ((dropmenuobj.y-topedge)<dropmenuobj.contentmeasure) //up no good either?
edgeoffset=dropmenuobj.y+obj.offsetHeight-topedge
}
}
return edgeoffset
}

function populatemenu(what){
if (ie4||ns6)
dropmenuobj.innerHTML=what.join("")
}


function dropdownmenu(obj, e, menucontents, menuwidth){
if (window.event) event.cancelBubble=true
else if (e.stopPropagation) e.stopPropagation()
clearhidemenu()
dropmenuobj=document.getElementById? document.getElementById("dropmenudiv") : dropmenudiv
populatemenu(menucontents)

if (ie4||ns6){
showhide(dropmenuobj.style, e, "visible", "hidden", menuwidth)
dropmenuobj.x=getposOffset(obj, "left")
dropmenuobj.y=getposOffset(obj, "top")
//dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(obj, "rightedge")+"px"
//dropmenuobj.style.left=dropmenuobj.x-50+"px"
dropmenuobj.style.left=dropmenuobj.x+"px"
dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(obj, "bottomedge")+obj.offsetHeight+"px"
}
var menuIframe, menu;
if (ie5){
menu=document.getElementById("dropmenudiv");
menuIframe=document.getElementById("myMenuIFrame1");

menuIframe.style.width=menuwidth;
menuIframe.style.height=50;
menuIframe.style.top=dropmenuobj.style.top;
menuIframe.style.left=dropmenuobj.style.left;
menuIframe.style.zIndex=menu.style.zIndex - 1;
menuIframe.style.display="block";
}
return clickreturnvalue()
}

function clickreturnvalue(){
if (ie4||ns6) return false
else return true
}

function contains_ns6(a, b) {
while (b.parentNode)
if ((b = b.parentNode) == a)
return true;
return false;
}

function dynamichide1(e){
if (ie4&&!dropmenuobj.contains(e.toElement))
delayhidemenu1()
else if (ns6&&e.currentTarget!= e.relatedTarget&& !contains_ns6(e.currentTarget, e.relatedTarget))
delayhidemenu1()
}

function hidemenu(e){
if (typeof dropmenuobj!="undefined"){
if (ie4||ns6)
dropmenuobj.style.visibility="hidden"
}
hideiframe()
}

function delayhidemenu1(){
if (ie4||ns6)
delayhide=setTimeout("hidemenu()",disappeardelay1)
hideiframe()

}

function clearhidemenu(){
if (typeof delayhide!="undefined")
clearTimeout(delayhide)
hideiframe()

}

if (hidemenu_onclick=="yes")
document.onclick=hidemenu

function hideiframe()
{
var menuIframe, menu;
if(ie5){
menu=document.getElementById("dropmenudiv");
menuIframe=document.getElementById("myMenuIFrame1");

menuIframe.style.width=0;
menuIframe.style.height=00;
menuIframe.style.top=0;
menuIframe.style.left=0;
menuIframe.style.zIndex=menu.style.zIndex - 1;
menuIframe.style.display="block";
}	
}


