//  WAYANAY INKA - Main navigation menu

//  Copyright (c) 2008 WAYANAY INKA - All Rights Reserved

var NO_MENU = false

//  Where are we?
var where = ''
for (j = document.URL.length; j > 0; j--) {
  if (document.URL.charAt(j) == "/" || document.URL.charAt(j) == "\\") break
  where = document.URL.charAt(j) + where
}
  
function popWin(URL, width, height) {
  window.open(URL,"", "width=" + width + ",height=" + height + 
  ",screenX=50,screenY=50,resizable=0,toolbar=0,directories=0,status=0,menubar=0,scrollbars=0")
}

function put2(s) {
  document.write(s)
}

function put(s1, s2) {
  //  No file specifier defaults to 'index.html'.
  if (where == '' && s1 == 'index.html' || s1 != '' && where == s1 || s1 == 'guestbook.html' && where == 'gbbottom.html' 
    || s1 == 'instruments.html' && where == 'instruments_main.html')
    //  This menu entry corresponds to the active page showing.
    put2('&nbsp;&nbsp;' + s2 + '&nbsp;&nbsp;')
  else
    if (s1 != '')
      //  This menu entry does not correspond to the active page showing.
      put2('&nbsp;&nbsp;<A HREF="' + s1 + '" TARGET=_top ONMOUSEOVER="ALLOW=true" ONMOUSEOUT="ALLOW=false">' + s2 + '</A>&nbsp;&nbsp;')
}

function put3(s1, s2) {
  put2('&nbsp;&nbsp;<A HREF="' + s1 + '" TARGET=_blank>' + s2 + '</A>&nbsp;&nbsp;')
}

function getParString() {
  URLString = new String(window.location)
  startIndex = URLString.indexOf('?')
  if (startIndex == -1) return ''
  return URLString.slice(startIndex + 1, URLString.length )
}

function showMenu() {
  NO_MENU = unescape(getParString()) == 'nomenu'
  if (NO_MENU ) return
  put2('<FONT SIZE=-1 FACE="ARIAL,HELVETICA">')
  //put2('<P>')
  //put2('<P>')

  put2('<P>About WAYANAY INKA and Per&uacute;<BR>')
  put("index.html", "Home")
  put("thegroup.html", "The&nbsp;Group")
  put("comments.html", "Comments")
  put("magic.html", "The&nbsp;Magic")
  put("instruments.html", "Instruments")
  put("inkas.html", "The&nbsp;Inkas")
  put2('<BR>')
  put("mercado.html", "Market&nbsp;Square")
  put("fans.html", "Fan&nbsp;Gallery")
  put("contact.html", "How&nbsp;to&nbsp;Contact")
  put("ack.html", "Acknowledgements")
  put2('</P>')
  put2('<P>')

  put2('<P>Music from Their Latest CDs<BR>')
  put("navidad.html", "Christmas")
  put("condor.html", "The&nbsp;Flight&nbsp;of&nbsp;the&nbsp;Condor")
  put("andes.html", "WAYANAY&nbsp;INKA&nbsp;...de&nbsp;los&nbsp;Andes")
  put2('<BR>')
  put("enchanted.html", "Enchanted&nbsp;Feelings")
  put("andean_world.html", "Andean&nbsp;World")
  put("bach.html", "Bach")
  put2('</P>')

  put2('<P>Videos<BR>')
  put2('<A HREF="javascript:popWin(\'dulce_jazmine.html\',\'425\',\'350\');">Dulce Jazmine</A>&nbsp;&nbsp;&nbsp;&nbsp;')
  put2('<A HREF="javascript:popWin(\'inka_dreams.html\',\'425\',\'350\');">Sue&ntilde;os del Inka</A>&nbsp;&nbsp;&nbsp;&nbsp;')
  put2('<A HREF="javascript:popWin(\'bamboo.html\',\'425\',\'350\');">Bamb&uacute;</A>&nbsp;&nbsp;&nbsp;&nbsp;')
  put2('<A HREF="javascript:popWin(\'coral.html\',\'425\',\'350\');">Coral</A>&nbsp;&nbsp;&nbsp;&nbsp;')
  put2('<A HREF="javascript:popWin(\'regresa_amor.html\',\'425\',\'350\');">Regresa Amor</A><BR>')
  put2('<A HREF="javascript:popWin(\'pastorcita.html\',\'425\',\'350\');">Pastorcita</A>&nbsp;&nbsp;&nbsp;&nbsp;')
  put2('<A HREF="javascript:popWin(\'pastorcita_remake.html\',\'425\',\'350\');">Pastorcita (Remake)</A>&nbsp;&nbsp;&nbsp;&nbsp;')
  put2('<A HREF="javascript:popWin(\'live_in_dallas.html\',\'425\',\'350\');">Live in Dallas</A>&nbsp;&nbsp;&nbsp;&nbsp;')
  put2('<A HREF="javascript:popWin(\'live_in_new_york.html\',\'425\',\'350\');">Live in New York</A></P>')


  put2('<P>')
  put2('<P>Supervised Guestbook for Viewers of All Ages<BR>') 
  put("guestbook.html", "View&nbsp;the&nbsp;Guestbook")
  put("guestbook_sign.html", "Sign&nbsp;the&nbsp;Guestbook")
  put2('</P>')

  put2('<P>')
  put2('<P>How to Order CDs<BR>')
  put("order_plain.html", "Call,&nbsp;Fax,&nbsp;or&nbsp;Mail&nbsp;Your&nbsp;Order")
  put("online_store.html", "Order&nbsp;On&nbsp;Line")
  put2('</P>')
}

showMenu()