//Extra code to find position:
function findPos(){
  if(bw.ns4){   //Netscape 4
    x = document.layers.layerMenu.pageX
    y = document.layers.layerMenu.pageY
  }else{ //other browsers
    x=0; y=0; var el,temp
    el = bw.ie4?document.all["divMenu"]:document.getElementById("divMenu");
    if(el.offsetParent){
      temp = el
      while(temp.offsetParent){ //Looping parent elements to get the offset of them as well
        temp=temp.offsetParent; 
        x+=temp.offsetLeft
        y+=temp.offsetTop;
      }
    }
    x+=el.offsetLeft
    y+=el.offsetTop
  }
  //Returning the x and y as an array
  return [x,y]
}

pos = findPos()

//Menu object creation
oCMenu=new makeCM("oCMenu") //Making the menu object. Argument: menuname

//Menu properties   
oCMenu.pxBetween=2

//Using the cm_page object to place the menu ----
oCMenu.fromLeft=pos[0]
oCMenu.fromTop=pos[1]

//We also need to "re place" the menu on resize. So:
oCMenu.onresize="pos = findPos(); oCMenu.fromLeft=pos[0]; oCMenu.fromTop=pos[1]"
oCMenu.rows=0
oCMenu.menuPlacement="top"
oCMenu.resizeCheck=1 
oCMenu.wait=700 
oCMenu.zIndex=0

//Background bar properties
oCMenu.useBar=1
oCMenu.barWidth="menu"
oCMenu.barHeight="menu" 
oCMenu.barClass="clBar"
oCMenu.barX="menu"
oCMenu.barY="menu"
oCMenu.barBorderX=0
oCMenu.barBorderY=0
oCMenu.barBorderClass=""

//Level properties - ALL properties have to be specified in level 0
oCMenu.level[0]=new cm_makeLevel() //Add this for each new level
oCMenu.level[0].width=131
oCMenu.level[0].height=30 
oCMenu.level[0].regClass="clLevel0"
oCMenu.level[0].overClass="clLevel0over"
oCMenu.level[0].borderX=1
oCMenu.level[0].borderY=1
oCMenu.level[0].borderClass="clLevel0border"
oCMenu.level[0].offsetX=-40
oCMenu.level[0].offsetY=7
oCMenu.level[0].rows=0
oCMenu.level[0].arrow=0
oCMenu.level[0].arrowWidth=0
oCMenu.level[0].arrowHeight=0
oCMenu.level[0].align="right"

//SubMenu properties
oCMenu.level[1]=new cm_makeLevel() //Add this for each new level
oCMenu.level[1].width=200
oCMenu.level[1].height=25 
oCMenu.level[1].regClass="clLevel0"
oCMenu.level[1].overClass="clLevel0over"
oCMenu.level[1].borderX=1
oCMenu.level[1].borderY=1
oCMenu.level[1].borderClass="clLevel0border"
oCMenu.level[1].offsetX=358
oCMenu.level[1].offsetY=7
oCMenu.level[1].rows=0
oCMenu.level[1].arrow=0
oCMenu.level[1].arrowWidth=0
oCMenu.level[1].arrowHeight=0
oCMenu.level[1].align="left"

//SubMenu properties
oCMenu.level[2]=new cm_makeLevel() //Add this for each new level
oCMenu.level[2].width=200
oCMenu.level[2].height=25 
oCMenu.level[2].regClass="clLevel0"
oCMenu.level[2].overClass="clLevel0over"
oCMenu.level[2].borderX=1
oCMenu.level[2].borderY=1
oCMenu.level[2].borderClass="clLevel0border"
oCMenu.level[2].offsetX=230
oCMenu.level[2].offsetY=7
oCMenu.level[2].rows=0
oCMenu.level[2].arrow=0
oCMenu.level[2].arrowWidth=0
oCMenu.level[2].arrowHeight=0
oCMenu.level[2].align="left"

/******************************************
Menu item creation:
myCoolMenu.makeMenu(name, parent_name, text, link, target, width, height, regImage, overImage, regClass, overClass , align, rows, nolink, onclick, onmouseover, onmouseout) 
*************************************/
oCMenu.makeMenu('top0','','Home','http://webs.wichita.edu/ielc-lab/')

oCMenu.makeMenu('top1','','Policy & Grading','')
	oCMenu.makeMenu('sub11','top1','Lab Policy','http://webs.wichita.edu/ielc-lab/policy.html')
	oCMenu.makeMenu('sub12','top1','How Grades Are Calculated','http://webs.wichita.edu/ielc-lab/grades.html')
	oCMenu.makeMenu('sub13','top1','Make-Ups','http://webs.wichita.edu/ielc-lab/make-up-schedule.html')

oCMenu.makeMenu('top2','','Living in Wichita','')
	oCMenu.makeMenu('sub21','top2','Wichita Apartments','http://www.kansasapartments.com/metro.cfm?metro=Wichita')
	oCMenu.makeMenu('sub22','top2','Driving License','http://www.ksrevenue.org/dmvdrlic.htm')
	oCMenu.makeMenu('sub23','top2','Car Tags & Insurance','http://www.sedgwick.ks.us/tag_office/renewal_dates.html#Insurance%20Verification%20Requirements')
	oCMenu.makeMenu('sub24','top2','Social Security Office','http://www.srskansas.org/rehab/text/social_security_offices.htm')
	oCMenu.makeMenu('sub25','top2','Student Visas','http://uscis.gov/graphics/howdoi/academic.htm')
	oCMenu.makeMenu('sub26','top2','Wichita Maps','http://www.wichitalinks.com/wichitamaps.html')
	oCMenu.makeMenu('sub27','top2','Wichita Weather','http://www.weather.com/weather/local/67201?GO=GO')

oCMenu.makeMenu('top3','','Lab Software','')

	oCMenu.makeMenu('sub31','top3','TOEFL Preparation','')
	oCMenu.makeMenu('sub310','sub31','ESL-CTS','http://webs.wichita.edu/ielc-lab/software/esl-cts.html')
	oCMenu.makeMenu('sub311','sub31','Listening Tests','http://webs.wichita.edu/ielc-lab/software/toefl-listening.html')
	oCMenu.makeMenu('sub312','sub31','Mini-Tests','http://webs.wichita.edu/ielc-lab/software/mini-tests.html')
	oCMenu.makeMenu('sub313','sub31','Recognizing Sounds','http://webs.wichita.edu/ielc-lab/software/recognizing-sounds.html')
	oCMenu.makeMenu('sub314','sub31','Understanding Situations','http://webs.wichita.edu/ielc-lab/software/understanding-situations.html')

oCMenu.makeMenu('sub32','top3','Listening Comprehension','')
	oCMenu.makeMenu('sub320','sub32','General Comprehension','http://webs.wichita.edu/ielc-lab/software/general-comprehension.html')
	oCMenu.makeMenu('sub321','sub32','Dictation','http://webs.wichita.edu/ielc-lab/software/dictation.html')
	oCMenu.makeMenu('sub322','sub32','Dialogs','http://webs.wichita.edu/ielc-lab/software/dialogs.html')
	oCMenu.makeMenu('sub323','sub32','Cloze Activities','http://webs.wichita.edu/ielc-lab/software/cloze-activities.html')
	oCMenu.makeMenu('sub324','sub32','Video Vocabulary','http://webs.wichita.edu/ielc-lab/software/video-vocabulary.html')

oCMenu.makeMenu('sub33','top3','Reading & Studying Skills','')
	oCMenu.makeMenu('sub330','sub33','Academic Lectures','http://webs.wichita.edu/ielc-lab/software/academic-lectures.html')
	oCMenu.makeMenu('sub331','sub33','Reading Cards','http://webs.wichita.edu/ielc-lab/software/reading-cards.html')
	oCMenu.makeMenu('sub332','sub33','Reading Notes','http://webs.wichita.edu/ielc-lab/software/reading-notes.html')
	oCMenu.makeMenu('sub333','sub33','Note-Taking','http://webs.wichita.edu/ielc-lab/software/note-taking.html')
	oCMenu.makeMenu('sub334','sub33','Science Videos','http://webs.wichita.edu/ielc-lab/software/science-videos.html')
	oCMenu.makeMenu('sub335','sub33','Timed Readings','http://webs.wichita.edu/ielc-lab/software/timed-readings.html')

oCMenu.makeMenu('sub34','top3','Writing Skills','')
	oCMenu.makeMenu('sub342','sub34','Adjective Clauses','http://webs.wichita.edu/ielc-lab/software/adjective-clauses.html')
	oCMenu.makeMenu('sub343','sub34','Sentence Order','http://webs.wichita.edu/ielc-lab/software/sentence-order.html')
	oCMenu.makeMenu('sub344','sub34','Paraphrasing','http://webs.wichita.edu/ielc-lab/software/paraphrasing.html')
	oCMenu.makeMenu('sub345','sub34','Word Processing','http://webs.wichita.edu/ielc-lab/software/word-processing.html')
	oCMenu.makeMenu('sub346','sub34','MLA Works Cited','http://webs.wichita.edu/ielc-lab/software/mla.html')

oCMenu.makeMenu('sub35','top3','Other Original Activities','')
	oCMenu.makeMenu('sub350','sub35','Word Scramble','http://webs.wichita.edu/ielc-lab/software/word-scramble.html')
	oCMenu.makeMenu('sub352','sub35','Kansas Driving Laws','http://webs.wichita.edu/ielc-lab/software/kdl.html')
	oCMenu.makeMenu('sub353','sub35','Wichita Map','http://webs.wichita.edu/ielc-lab/software/wichita-map.html')
	oCMenu.makeMenu('sub354','sub35','Fixes','http://webs.wichita.edu/ielc-lab/software/fixes.html')
	oCMenu.makeMenu('sub355','sub35','HTML','http://webs.wichita.edu/ielc-lab/software/html.html')
	oCMenu.makeMenu('sub356','sub35','PowerPoint','http://webs.wichita.edu/ielc-lab/software/power-point.html')

oCMenu.makeMenu('sub36','top3','Commercial Titles','http://webs.wichita.edu/ielc-lab/software/commercial-programs.html')

oCMenu.makeMenu('sub37','top3','World News Review','http://webs.wichita.edu/ielc-lab/wnr/playerlaunch.html')

oCMenu.makeMenu('sub38','top3','NetEnglish Webbrowser','http://webs.wichita.edu/ielc-lab/NetEnglish')

oCMenu.makeMenu('top4','','TOEFL Information','')
	oCMenu.makeMenu('sub41','top4','General Information (ETS)','http://www.ets.org/portal/site/ets/menuitem.435c0b5cc7bd0ae7015d9510c3921509/?vgnextoid=69c0197a484f4010VgnVCM10000022f95190RCRD')
	oCMenu.makeMenu('sub42','top4','TOEFL Requirements at WSU','http://webs.wichita.edu/ielc-lab/TOEFL-Requirement.html')
	oCMenu.makeMenu('sub43','top4','Prometric Testing Center','http://webs.wichita.edu/ielc-lab/prometric.html')
	oCMenu.makeMenu('sub44','top4','Institutional TOEFL','http://webs.wichita.edu/ielc-lab/TOEFL-Comparison.htm')


oCMenu.makeMenu('top6','','Conversation','http://webs.wichita.edu/ielc-lab/conversation.html')

oCMenu.makeMenu('top7','','Class Pages','')
	oCMenu.makeMenu('sub71','top7','Thomas: Intermediate II S/L','http://webs.wichita.edu/ielc-lab/Thomas/announcements-int2.html')
	oCMenu.makeMenu('sub72','top7','Thomas: Advanced I S/L','http://webs.wichita.edu/ielc-lab/Thomas/announcements-adv1.html')
	oCMenu.makeMenu('sub73','top7','Thomas: Advanced II S/L','http://webs.wichita.edu/ielc-lab/Thomas/announcements-adv2.html')
	oCMenu.makeMenu('sub74','top7','Journal Writing Topics','http://webs.wichita.edu/ielc-lab/Journals/topics.html')
	oCMenu.makeMenu('sub75','top7','IAS Briefcase Pages','http://webs.wichita.edu/ielc-lab/briefcase/index.html')

oCMenu.makeMenu('top8','','E-mail Sites','')
	oCMenu.makeMenu('sub81','top8','WSU Webmail','https://exchange-01.ad.wichita.edu/owa/auth/logon.aspx?replaceCurrent=1&url=https%3a%2f%2fexchange-01.ad.wichita.edu%2fowa%2f','',120)
	oCMenu.makeMenu('sub82','top8','Hotmail','http://www.hotmail.com','',120)
	oCMenu.makeMenu('sub83','top8','Yahoo','http://mail.yahoo.com','',120)
	oCMenu.makeMenu('sub84','top8','Mail.com','http://www.mail.com','',120)
	
oCMenu.makeMenu('top9','','News Sites','')
	oCMenu.makeMenu('sub91','top9','Wichita Eagle','http://www.kansas.com/mld/kansas/news/')
	oCMenu.makeMenu('sub92','top9','Google News','http://news.google.com')
	oCMenu.makeMenu('sub93','top9','News off the Wire','http://www.abcnews.go.com/wire/world/')
	oCMenu.makeMenu('sub94','top9','CNN','http://www.cnn.com/')
	oCMenu.makeMenu('sub95','top9','BBC News','http://www.bbc.co.uk/worldservice/index.shtml')
	oCMenu.makeMenu('sub96','top9','MSNBC News','http://www.msnbc.com/news/default.asp')
	oCMenu.makeMenu('sub97','top9','Yahoo','http://dailynews.yahoo.com/')

oCMenu.makeMenu('top10','','Contact Us','http://webs.wichita.edu/ielc-lab/mailer.html')

oCMenu.construct()