//SET SELECTED FLAGS

// Instructions:
//
// Set a blank var XYZ_SELECTED for each top level nav category
// Set the filename/wildcards for which that variable should contain " class=SELECTED"
// Add the variable to the writeln code below for each section so that " class=SELECTED" is written for the correct filename(s).


var HOME_SELECTED = '';
var DESIGN_SELECTED = '';
var SHOWROOM_SELECTED = '';
var SHOWCASE_SELECTED = '';
var CUSTOM_SELECTED = '';
var ABOUT_SELECTED = '';


var fileName = location.pathname.substring(location.pathname.lastIndexOf('/')+1);


if (fileName == 'index.html' || fileName == '') {	HOME_SELECTED = ' class=SELECTED'; }
if (fileName == 'showcase.html') { SHOWCASE_SELECTED = ' class=SELECTED'; }
if (fileName.indexOf('int_') >= 0) { DESIGN_SELECTED = ' class=SELECTED'; }
if (fileName.indexOf('showroom') >= 0) { SHOWROOM_SELECTED = ' class=SELECTED'; }
if (fileName == 'custom.html') { CUSTOM_SELECTED = ' class=SELECTED'; }
if (fileName.indexOf('about') >= 0) { ABOUT_SELECTED = ' class=SELECTED'; }



document.writeln('<TABLE class="MAIN_NAVIGATION">'); // cellspacing is not deprecated yet
document.writeln('<TR>');
document.writeln('<td' + HOME_SELECTED + '><a href="index.html">HOME</a></td>');
document.writeln('<td' + DESIGN_SELECTED + '><a href="int_1.html">INTERIOR<BR>DESIGN</a></td>');
document.writeln('<td' + SHOWCASE_SELECTED + '><a href="showcase.html">PRODUCT<BR>SHOWCASE</a></td>');
//document.writeln('<td' + CUSTOM_SELECTED + '><a href="custom.html">IREKO<BR>CUSTOM</a></td>');
document.writeln('<td' + SHOWROOM_SELECTED + '><a href="showroom.html">VISIT OUR<BR>SHOWROOM</a></td>');
document.writeln('<td' + ABOUT_SELECTED + '><a href="about.html">ABOUT<BR>IREKO</a></td>');
document.writeln('</TR>');
document.writeln('</TABLE>');


