var sellink;

var links = [
"what",
"who",
"when", 
//"where",
"daily", 
//"sign",
"price",
"slides"
];

function resetAll() {
  for (var i = 0; i < links.length; ++i) {
    $("#"+links[i]).css("font-weight","normal");
    $("#"+links[i]).css("color","#000");
  }
}

function set(which) {
  sellink = which
  $("#" + which).css("font-weight","bold");  
  $("#" + which).css("color","#c00");  
}

$(function() {

  for (var i = 0; i < links.length; ++i) {
    $("#" + links[i]).mouseover(function(){
      if (this.id != sellink)
        this.style.fontWeight = "bold";
    })
    $("#" + links[i]).mouseout(function(){
      if (this.id != sellink)
      this.style.fontWeight = "normal";
    })
  }

  $("#what").click(function(){ 
    $.get( "camp/what.html", null, 
      function(data) {
        $("#campcontent").html(data)
      })
    resetAll(); set("what");
  })

  $("#who").click(function(){ 
    $.get( "camp/who.html", null, 
      function(data) {
        $("#campcontent").html(data)
      })
    resetAll(); set("who");
  })

  $("#when").click(function(){ 
    $.get( "camp/when.html", null, 
      function(data) {
        $("#campcontent").html(data)
      })
    resetAll(); set("when");
  })

/*
  $("#where").click(function(){ 
    $.get( "camp/where.html", null, 
      function(data) {
        $("#campcontent").html(data)
      })
    resetAll(); set("where");
  })


  $("#sign").click(function(){
    $.get( "camp/sign.html", null,
      function(data) {
        $("#campcontent").html(data)
      })
    resetAll(); set("sign");
  })

*/

  $("#daily").click(function(){ 
    $.get( "camp/daily.html", null, 
      function(data) {
        $("#campcontent").html(data)
      })
    resetAll(); set("daily");
  })

  $("#slides").click(function(){ 
    $.get( "camp/slides.html", null, 
      function(data) {
        $("#campcontent").html(data)
      })
    resetAll(); set("slides");
  })

  $("#price").click(function(){ 
    $.get( "camp/price.html", null, 
      function(data) {
        $("#campcontent").html(data)
      })
    resetAll(); set("price");
  })

})
