function makeBold(cellNum, divname){
var x = document.getElementById("toc").rows[cellNum].cells[0].innerHTML;
if(x.toUpperCase().indexOf("<B>") == -1)
document.getElementById("toc").rows[cellNum].cells[0].innerHTML="<b>"+x+"</b>";
document.getElementById(divname).style.visibility="visible";
}
function unBold(cellNum, divname){
var x = document.getElementById("toc").rows[cellNum].cells[0].innerHTML;
if(x.toUpperCase().indexOf("<B>") >= 0)
document.getElementById("toc").rows[cellNum].cells[0].innerHTML=x.substring(3,(x.length-4));
document.getElementById(divname).style.visibility="hidden";
//alert(document.getElementById("toc").rows[cellNum].cells[0].innerHTML)
}


//list of pages that should not have the standard random picture
var nopics = new Array("index.html", "membership_form.html", "geo_riddles.html", "300_names_page.html", "300_names_definitions", "famous5.htm");

//check if page should have the standard random picture
var url = document.URL;
//var page = url.substring(url.lastIndexOf("/")+1,url.length);
var dopic = 1;
for(index=0;index < nopics.length;index++){
    if(url.indexOf(nopics[index]) != -1 ||
        url.indexOf('.htm') == -1){
        dopic=0;
        break;
    }
}

if(dopic==1){
    var picsArray = new Array("images/pf/mt10060.jpg", "Photo: Looking southwest to Mount 10060 from Highway #93 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/mt10240.jpg", "Photo: Looking southwest to Mount 10240 from Highway 93 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/mtaberdeen.jpg", "Photo: Haddo Peak (left) and Mount Aberdeen from the north on Highway #93 at Herbert Lake (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/abrahammtn2.jpg", "Photo: Abraham Mountain from the south on Highway #11 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/mtandromache2.jpg", "Photo: Mount Andromache from the northwest on Highway #93 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/mtandromache.jpg", "Photo: Mount Andromache from the northwest on Highway #93 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/mtdesmet.jpg", "Photo: Looking north to Mount De Smet from Highway #95 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/oubliettemtn.jpg", "Photo: (l-r) Parapet Mountain, Paragon Peak, Oubliette Peak, Dungeon Peak, Redoubt Peak from the east (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/cougarmtn.jpg", "Photo: Cougar Mountain from the west in the lower Piper Creek Valley. Cougar Mountain is an 'L' shaped peak with three summits. (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/bullcreekhills.jpg", "Photo: Bull Creek Hills (Holy Cross Mountain beyond) from the east on Highway #541 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/bullcreekhills2.jpg", "Photo: Bull Creek Hills from the west on Holy Cross Mountain (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/campionmtn2.jpg", "Photo: Campion Mountain from the southeast on Highway #16 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/cathedralcrags.jpg", "Photo: Cathedral Crags at sunset from the Trans-Canada Highway near the Spiral Tunnel Viewpoint (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/cegnfs.jpg", "Photo: Cegnfs from the Smith-Dorrien Valley near James Walker Creek (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/halingpk.jpg", "Photo: Ha Ling Peak from Highway #1A near Canmore (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/hailstonebutte.jpg", "Photo: Looking west-southwest to Hailstone Butte from Hwy. #532 (Johnson Creek Valley) (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/hilloftheflowers2.jpg", "Photo: The Hill of the Flowers from the east on Holy Cross Mountain (beyond l-r) Mount Abruzzi, Mount Bishop, Mount Cadorna, Mount Swiderski, Mount Battisti (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/hilloftheflowers.jpg", "Photo: Mount Bishop (left), The Hill of the Flowers, and Odlum Ridge from Hwy. #40 on the hill just north of Cat Creek (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/sealionmtn.jpg", "Photo: Looking south to Sea Lion Mountain (beyond) from the Blaeberry Valley Road (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/sevensistersmtn.jpg", "Photo: Seven Sisters Mountain from Highway #3 near Blairmore (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/stnicholaspk.jpg", "Photo: St. Nicholas Peak from Highway #93 near Bow Lake (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/stormmtnkan.jpg", "Photo: Looking east-northeast to Storm Mountain from Highwood Ridge (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/yellowheadmtn.jpg", "Photo:Looking northwest to Yellowhead Mountain (l-r Bingley Peak, Leather Peak, Lucerne Peak, and Tete Roche) from Highway #16 at the east end of Yellowhead Lake (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/lysridge.jpg", "Photo: Lys Ridge from Highway #774 near the confluence of the Castle and West Castle Rivers (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/makwaridge.jpg", "Photo: Makwa Ridge from Highway #16 near Disaster Point (un-named summits in the distance at right) (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/massivemtn.jpg", "Photo: Massive Mountain with Mount Brett (left) and Pilot Mountain (right) from the northwest on the Bow Valley Parkway (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/merlincastle.jpg", "Photo: Merlin Castle from the east above Merlin Lake (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/middlesister.jpg", "Looking south-southeast to Middle Sister from the Trans-Canada Highway (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/missinglinkmtn.jpg", "Photo: Looking east to Missinglink Mountain from Mount Ware (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/themitre.jpg", "Photo: The Mitre from Plain of the Six Glaciers (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/mistmtn2.jpg", "Photo: Mist Mountain from the southeast on Highway #40 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/mtxerxes3.jpg", " Photo: Looking up Fryatt Creek Valley to Mount Xerxes (left) and Mount Olympus from Highway #93 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/outlawpk2.jpg", "Photo: Looking southwest to (l-r) Banded Peak, Outlaw Peak, Mount Cornwall, and Mount Glasgow from the east on Highway #22 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/mtpeskett.jpg", "Photo: Looking south to Mount Peskett from Highway #11 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/peverilpk.jpg", "Photo: Peveril Peak looking through 'The Portal' from Highway #93 (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/pf/pincherridge.jpg", "Photo: Pincher Ridge (left) and Victoria Peak (right) from the east (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    "images/mps/indianhead_mountain_s.jpg", "Indian Head Mountain (peak in middle is top of headdress, small bump to right is nose) (courtesy Michael Semenchuk)",
    "images/mps/mountain_park_s.gif", "Overlooking the old Mountain Park Townsite (cemetary in foreground) (courtesy Michael Semenchuk)",
    "images/mps/whitehorse_creek.gif", "Waterfall on Whitehorse Creek (courtesy Michael Semenchuk)",
    "images/mps/whitehorse_creek2.gif", "Waterfall on Whitehorse Creek (courtesy Michael Semenchuk)",
    "images/mps/whitehorse_creek3.gif", "Looking northwest down Whitehorse Creek (courtesy Michael Semenchuk)")
    //"images/pf/", " (courtesy <a href='http://peakfinder.com' target='_blank'>Peakfinder.com</a>)",
    no=Math.random()*(picsArray.length/2)
    picNum = Math.round(no)
    if(picNum*2 >= picsArray.length)
    picNum = picNum-1;
    piccontent = "<img src='"+picsArray[picNum*2]+"'><h6>"+picsArray[(picNum*2)+1]+"</h6>";//arraylength:"+picsArray.length+" div2:"+(picsArray.length/2)+" no:"+no+" picnum:"+picNum;
    document.getElementById("pictable").rows[0].cells[0].innerHTML= piccontent;
}