////////////////////////////////////////////////////////////
//                                                        //
// standard.js - client use JavaScript library module     //
//                                                        //
// Copyright : (c) 1998,99-00,03 all rights reserved by   //
//                 Technical System Services Limited      //
//                                                        //
//============={ Version: 2.1 - SC 25/04/03 }=============//

var now = new Date();                              // read system clock
var nowYear = now.getYear();
nowYear += "";
nowYear = nowYear.substr(2,2);
var copyRightDates = "2000-" + nowYear;

////////////////////////////////////////////////////////////
//                                                        //
// footer() - generate a 'customer specific' line footer. //
//                                                        //
//============={ Version: 6.0 - SC 03/04/03 }=============//

function footer() {

   document.write('<CENTER>');
   document.write('<TABLE WIDTH=758 CELLPADDING=1 CELLSPACING=1');
   document.write(' BORDER=0>');
   document.write('<TR><TD ALIGN=CENTER>');
   document.write('<IMG SRC="image/acm-bar.gif" HEIGHT=1 WIDTH=690>');
   document.write('</TD></TR>');
   document.write('<TR><TD ALIGN=CENTER>');
   document.write('<SPAN CLASS=tiny>');
   document.write('<SPAN CLASS=heavy>');
   document.write('<EM>Airconstruct (Midlands) Limited</EM></SPAN>, ');
   document.write('<SPAN CLASS=darkgray><B>');
   document.write('ACM House, Littleton Drive, ');
   document.write('Huntington, Staffs, WS12 4TS');
   document.write('</SPAN>');
   document.write(' - all rights reserved &copy; ');
   document.write(copyRightDates + '</B>');
   document.write('</SPAN>');
   document.write('</TD>');
   document.write('</TR>');
   document.write('</TABLE>');
   document.write('</CENTER>');

}

////////////////////////////////////////////////////////////
//                                                        //
// mast_head(where) ...                                   //
//                                                        //
//============={ Version: 2.0 - SC 21/04/03 }=============//

function mast_head(where) {

   document.write('<CENTER>');
   document.write('<TABLE WIDTH=758');
   document.write(' CELLSPACING=0 CELLPADDING=0 BORDER=0>');
   document.write('<TR>');

   document.write('<TD ROWSPAN=2 HEIGHT=45>');
   document.write('<A HREF="homepage.htm">');
   document.write('<IMG SRC="image/acm-logo.gif"');
   document.write(' ALT="ACM: homepage"');
   document.write(' WIDTH=171 HEIGHT=45 BORDER=0></A>');
   document.write('</TD>');
   document.write('<TD HEIGHT=37>');

   main_menu(where);

   document.write('</TD>');

   document.write('</TR><TR>');
   document.write('<TD HEIGHT=8>');
   document.write('<IMG SRC="image/top-bar.gif"');
   document.write(' ALT="Airconstruct (Midlands) Limited"');
   document.write(' WIDTH=587 HEIGHT=8>');
   document.write('</TD>');

   document.write('</TR><TR>');

   document.write('<TD WIDTH=171 HEIGHT=45 ROWSPAN=3>');
   document.write('<A HREF="javascript:history.go(-1)">');
   document.write('<IMG SRC="image/acm-upsidedown.gif"');
   document.write(' ALT="ACM: previous page"');
   document.write(' WIDTH=171 HEIGHT=45 BORDER=0></A>');
   document.write('</TD>');
   document.write('<TD WIDTH=587 VALIGN=TOP>');

   second_menu(where);

   document.write('</TD>');
   document.write('</TR><TR>');

   document.write('<TD ALIGN=CENTER WIDTH=587 HEIGHT=1>');
   document.write('<IMG SRC="image/acm-bar.gif" HEIGHT=1 WIDTH=587>');
   document.write('</TD>');
   document.write('</TR><TR>');

   document.write('<TD WIDTH=587 VALIGN=TOP>');

   contact_details(where);

   document.write('</TD>');
   document.write('</TR></TABLE>');

}

////////////////////////////////////////////////////////////
//                                                        //
// main_menu(where) - where is :-            "home"       //
//                                                        //
//============={ Version: 2.1 - SC 25/04/03 }=============//

function main_menu(where) {

   //
   // scan parameter to enable any page specific features
   var atAbout = (where.indexOf("about") != -1);
   var atFactory = (where.indexOf("factory") != -1);
   var atManufacture = (where.indexOf("manufacture") != -1);
   var atPromo = (where.indexOf("promo") != -1);
   var atProject = (where.indexOf("project") != -1);
   var atHome = (where.indexOf("home") != -1);
   var atMail = (where.indexOf("mail") != -1);

   document.write('<TABLE WIDTH=100% HEIGHT=28');
   document.write('       CELLPADDING=1 CELLSPACING=0 BORDER=0>');

   document.write('<TR ALIGN=CENTER VALIGN=CENTER>');

   document.write('<TD HEIGHT=28>');
   document.write('<SPAN CLASS=company>');
   document.write("AIRCONSTRUCT<BR>(MIDLANDS) Limited");
   document.write('</SPAN>');
   document.write('</TD>');

   document.write('<TD HEIGHT=28>');
   if (atAbout) {
      write_span("here", "menu", "about<BR>us");
   }
   else {
      write_href("aboutus.htm", "about<BR>us");
   }

   document.write('</TD><TD>');

   if (atFactory) {
      write_span("here", "menu", "factory<BR>facilities");
   }
   else {
      write_href("factory.htm",'factory<BR>facilities');
   }

   document.write('</TD><TD>');

   if (atManufacture) {
      write_span("here", "menu", "manufacturing<BR>process");
   }
   else {
      write_href("manufacture.htm",'manufacturing<BR>process');
   }

   document.write('</TD><TD>');

   if (atProject) {
      write_span("here", "menu", 'case<BR>studies');
   }
   else {
      write_href("projects.htm",'case<BR>studies');
   }

   document.write('</TD><TD>');

   if (atPromo) {
      write_span("here", "menu", 'promotion &<BR>marketing');
   }
   else {
      write_href("promotion.htm",'promotion &<BR>marketing');
   }

   document.write('</TD>');

   document.write('</TR></TABLE>');

}

////////////////////////////////////////////////////////////
//                                                        //
// second_menu(where) - where is :- like main_menu()      //
//                                                        //
//============={ Version: 2.0 - SC 21/04/03 }=============//

function second_menu(where) {

   //
   // scan parameter to enable any page specific features
   var atAircon = (where.indexOf("aircon") != -1);
   var atSurvey = (where.indexOf("survey") != -1);
   var atService = (where.indexOf("service") != -1);
   var atHire = (where.indexOf("hire") != -1);
   var atContact = (where.indexOf("contact") != -1);
   var atCommercial = (where.indexOf("commercial") != -1);

   document.write('<TABLE WIDTH=100% HEIGHT=28');
   document.write('       CELLPADDING=1 CELLSPACING=0 BORDER=0>');

   document.write('<TR ALIGN=CENTER VALIGN=CENTER>');

   document.write('<TD HEIGHT=28>');
   if (atAircon) {
      write_span("here", "menu", 'air<BR>conditioning');
   }
   else {
      write_href("aircon.htm", 'air<BR>conditioning');
   }

   document.write('</TD><TD>');

   if (atSurvey) {
      write_span("here", "menu", 'survey, design<BR>& consultancy');
   }
   else {
      write_href("survey.htm", 'survey, design<BR>& consultancy');
   }

   document.write('</TD><TD>');

   if (atService) {
      write_span("here", "menu", "service &<BR>maintenance");
   }
   else {
      write_href("service.htm", "service &<BR>maintenance");
   }

   document.write('</TD><TD>');

   if (atHire) {
      write_span("here", "menu", "hire &<BR>portables");
   }
   else {
      write_href("hire.htm", "hire &<BR>portables");
   }

   document.write('</TD><TD>');

   if (atCommercial) {
      write_span("here", "menu", 
                 'commercial,<BR>industrial & retail');
   }
   else {
      write_href("commercial.htm",
                 'commercial,<BR>industrial & retail');
   }
   document.write('</TD><TD>');

   if (atContact) {
      write_span("here", "menu", "contact<BR>us");
   }
   else {
      write_href("contact.htm",'contact<BR>us');
   }
   document.write('</TD>');

   document.write('</TR></TABLE>');

}

////////////////////////////////////////////////////////////
//                                                        //
// contact_details(where) - where is "home" ... "page" et //
//                                                        //
//============={ Version: 2.0 - SC 21/04/03 }=============//

function contact_details(where) {

   //
   // scan parameter to enable any page specific features
   var atHome = (where.indexOf("home") != -1);
   var atMail = (where.indexOf("mail") != -1);

   document.write('<TABLE WIDTH=100% xHEIGHT=28');
   document.write('       xBGCOLOR=#A0B2D0');
   document.write('       CELLPADDING=1 CELLSPACING=0 BORDER=0>');

   document.write('<TR ALIGN=CENTER VALIGN=CENTER>');
//   document.write('<TD>');
//   document.write('<SPAN CLASS=small>');
//   document.write('<EM>Airconstruct (Midlands) Ltd.</EM>');
//   document.write('</TD>');
   document.write('<TD>');
   document.write('<SPAN CLASS=small><SPAN CLASS=darkgray><B>');
   document.write('tel:</SPAN></B> 01543 572300');
   document.write('</TD>');
   document.write('<TD>');
   document.write('<SPAN CLASS=small><SPAN CLASS=darkgray><B>');
   document.write('fax:</SPAN></B> 01543 574090');
   document.write('</TD>');
   document.write('<TD>');
   document.write('<SPAN CLASS=small><SPAN CLASS=darkgray><B>');
   document.write('email:</SPAN> ');
   if (!atMail) {
      document.write('<A HREF="contact.htm#EMAIL">');
      document.write('<SPAN CLASS=small>');
   }
   document.write('sales@airconstruct.co.uk');
   if (!atMail) {
      document.write('</A>');
   }
   document.write('</TD>');
   document.write('</TR></TABLE>');

}
