///////////////////////////////////////////
//
// Copyright Textura 2002-2004
//
// Code may not be used, copied or modified 
// without permission.
//
//
///////////////////////////////////////////

// JAVASCRIPT - lcr.js

function lastupdate()
{
   if (Date.parse(document.lastModified) != 0)
   {
      var day = new Array("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday");
      var month = new Array("January","February","March","April","May","June","July","August", "September","October","November","December");
      var lastDate = new Date(document.lastModified);
      var yearno = lastDate.getFullYear();
      document.write('<i> ' + document.title + '.</i> Last Updated: ');
      document.write(day[lastDate.getDay()] + ', ');
      document.write(month[lastDate.getMonth()] + ' ');
      document.write(lastDate.getDate() + ', ');
      // To cover the case when system's aren't setup correctly!
      if (yearno < 2000)
      {
         yearno=yearno+100;
      }
      document.writeln(yearno);
   }
}

function pageFooter1()
{
   document.write ('</td></tr><tr><td colspan=2><HR></td></tr><tr><td colspan=2>');
   document.write ('<table align=center><tr>');
   document.write ('<td class=menux><a class=menux href="index.html" title="Return to Home page"');
   tag("home");
   document.write('</a></td>');
   document.write ('<td class=menux><a class=menux href="memberdir.htm" title="Membership Details"');
   tag("members");
   document.write('</a></td>');
   document.write ('<td class=menux><a class=menux href="countryactivity.htm" title="Activity by country"');
   tag("activity");
   document.write('</a></td>');
   document.write ('<td class=menux><a class=menux href="meeting.htm" title="Details of next meeting"');
   tag("meeting");
   document.write('</a></td>');
   document.write ('<td class=menux><a class=menux href="seminars.htm" title="Details of forthcoming seminars"');
   tag("seminars");
   document.write('</a></td>');
   //document.write ('<td class=menux><a class=menux href="offset_register.htm" title="Offset Regs"');
   //tag("offset regs");
   //document.write('</a></td>');
   //document.write ('<td class=menux><a class=menux href="articles.htm" title="Details of press articles"');
   //tag("press");
   //document.write('</a></td>');
   document.write ('<td class=menux><a class=menux href="links.htm" title="Some useful links"');
   tag("links");
   document.write('</a></td>');
   document.write ('<td class=menux><a class=menux href="contacts.htm" title="Details of key contacts"');
   tag("contacts");
   document.write('</a></td></tr></table>');
   document.write ('<table width=100% border=0 cellspacing=2 cellpadding=0><tr><td><h6>');
   lastupdate();
   // document.write ('<br>&copy;2002 <a href="http://www.textura.co.uk">Textura</a>. ');
   document.write ('<br>Designed by <a href="http://www.textura.co.uk">Textura</a>. ');
   document.write ('Please read our <a href="disclaimer.htm">Disclaimer</a> and ');
   document.write ('address any comments regarding this site to the <a href="mailto:webmaster@londoncountertrade.org?Subject=Comments on LCR website">Webmaster</a>');
   document.write ('<br>All material &copy; London Countertrade Roundtable</h6>');
   document.write ('</td><td>');
   document.write ('<p><a href="http://validator.w3.org/check/referer"><img class=w3logo src="http://www.w3.org/Icons/valid-html401" alt="Valid HTML 4.01!"></a>');
   document.write ('&nbsp;<a href="http://jigsaw.w3.org/css-validator/"><img class=w3logo src="http://jigsaw.w3.org/css-validator/images/vcss" alt="Valid CSS!"></a>');
   document.write ('</p></td></tr></table>');
   document.write ('</td></tr></table>');
}

function pageFooter()
{
   document.write ('</div>');
   document.write ('<div id="footer">');
   document.write ('Designed by <a href="http://www.textura.co.uk">Textura</a>. Please read our <a href="disclaimer.htm">');
   document.write ('Disclaimer</a> and address any comments regarding this site to the <a href="mailto:webmaster@londoncountertrade.org?Subject=Comments on LCR website">Webmaster</a>');
   document.write ('<br />All material &copy; London Countertrade Roundtable 2007');
   document.write ('<br class="doNotDisplay doNotPrint" />');
   document.write ('</div>');
}

function pageHeader1()
{
   document.write ('<TABLE summary=ph0 width="100%" border=0 cellPadding=0 cellSpacing=0>');
   document.write ('<tr><td colspan=2>');
   document.write ('<center id=top><img border="0" src="image/LCR_Logo.jpg" width="500" alt="London Counter Trade Roundtable"></center>');
   document.write ('<hr WIDTH="100%">');
   document.write ('</td></tr>');
   document.write ('<tr><td colspan=2 class=header>For companies and individuals engaged in the fields of countertrade, offset and related activities<hr width=100%></td></tr>');
   document.write ('<TR>');
   document.write ('<TD width=15% valign=top align=center>');
   document.write ('<table summary=ph1 bgcolor=#ffffff width=95% border=0 cellspacing=0 cellpadding=0><tr><td>');
   last_level=1;
   start_table();
   button(1,"Home","index.html","Return to Home page",0);
   button(1,"Members","#","Details of London Countertrade members",1);
   button(2,"Members Directory","memberdir.htm","Members Details",0);
   button(2,"Activity by country","countryactivity.htm","Activity by country",0);
   button(2,"Joining","joining.htm","Becoming a member",0);
   button(2,"Statutes","statutes.htm","London Countertrade Roundtable Statutues",0);
   button(1,"Events","#","Details of forthcoming events",1);
   button(2,"Next Meeting","meeting.htm","Details of next meeting",0);
   button(2,"Forthcoming Seminars","seminars.htm","Details of forthcoming seminars",0);
   button(2,"Past Events","pastevents.htm","Slides from past events",0);
   //button(1,"Offset Regs","offset_register.htm","Offset Register",0);
   //button(1,"Articles","articles.htm","Details of related press articles",0);
   button(1,"Links","links.htm","Some useful links",0);
   button(1,"Contacts","contacts.htm","Details of key contacts",0);
   document.write ('</table>');
   document.write ('</td></tr></table>');
   document.write('<br>');
   add_search();
   document.write ('</TD>');
   document.write ('<TD valign=top>');

   /* TEMP disable_handler(); */
}

function pageHeader()
{
     document.write (' <div class="midHeader">');
	 document.write (' <img class="headerImage" src="image/lcr_new1.jpg" alt="LCR Logo Image" width="220" />');
     document.write (' <h1 class="headerTitle">London Countertrade Roundtable</h1>');
     document.write (' </div>');
     document.write (' <div class="subHeader">');
     document.write (' <span class="doNotDisplay">Navigation:</span>');
     document.write (' For companies and individuals engaged in the fields of countertrade, offset and related activities');
     document.write (' </div>');
     /* document.write (' <div class="midHeader">');
	 document.write (' <img src="image/lcr_new.jpg" alt="LCR Logo Image" width="600" />');
     document.write (' </div>');
     */
     

     document.write (' <div id="side-bar">');
     document.write (' <div>');
     document.write ('  <ul>');
     document.write ('   <li><a href="index.html" title="Return to home page">Home</a></li>');
     document.write ('   <li><a href="links.htm" title="Some useful links">Links</a></li>');
     document.write ('   <li><a href="contacts.htm" title="Details of key contacts">Contacts</a></li>');
     document.write ('</ul>');
     document.write (' </div>');
     document.write ('<div>');
     document.write ('  <p class="sideBarTitle">Members</p>');
     document.write ('   <ul>');
     document.write ('     <li><a href="memberdir.htm" title="Members details">Members Directory</a></li>');
     document.write ('     <li><a href="countryactivity.htm" title="Activity by country">Activity by country</a></li>');
     document.write ('    <li><a href="joining.htm" title="<b>Members details</b>">Joining</a></li>');
     document.write ('    <li><a href="statutes.htm" title="London Countertrade Roundtable Statutues">Statutes</a></li>');
     document.write ('   </ul>');
     document.write ('     </div>');
     document.write ('      <div>');
     document.write ('        <p class="sideBarTitle">Events</p>');
     document.write ('        <ul>');
     document.write ('           <li><a href="meeting.htm" title="Details of next meeting">Next meeting</a></li>');
     document.write ('           <li><a href="seminars.htm" title="Details of forthcoming seminars">Forthcoming Seminars</a></li>');
     document.write ('           <li><a href="pastevents.htm" title="Slides from past events">Past Events</a></li>');
     document.write ('        </ul>');
     document.write ('      </div>');
     document.write ('    </div>');
     document.write ('<div id="main-copy">');
}

function add_search()
{
   document.write ('<table summary="search site" class=search width=95% border=0 cellspacing=0 cellpadding=0>');
   /* document.write ('<tr><td colspan=2>Site search</td></tr>'); */
   document.write ('<tr><td><A HREF="searchhelp.htm" TITLE="How to search this site">Help</A></td>');
   document.write ('<td><A HREF="advsearch.htm" TITLE="Advanced search">Advanced</A></td></tr>');
   document.write ('<tr><td colspan=2><!-- Atomz Search HTML for London Countertrade Roundtable -->');
   document.write ('<form method="get" action="http://search.atomz.com/search/">');
   document.write ('<input size=15 name="sp-q"><br>');
   document.write ('<input type=submit value="Search">');
   document.write ('<input type=hidden name="sp-a" value="sp100213bd">');
   document.write ('<input type=hidden name="sp-f" value="ISO-8859-1">');
   document.write ('</form></td></tr>');
   document.write ('</table>');
}

function disable_handler()
{
/*
Disable right mouse click Script
© Dynamic Drive (www.dynamicdrive.com)
For full source code, installation instructions,
100's more DHTML scripts, and Terms Of
Use, visit dynamicdrive.com
This script last updated:99/04/05
*/

if (document.all)
document.body.onmousedown=new Function("if (event.button==2||event.button==3)alert('Please contact webmaster')")
}

/////////////////////////////
///////               ///////
/////// Menu routines ///////
///////               ///////
/////////////////////////////

var action = false;
var last_name = "";
function display(name)
{
   // Remove any submenus on display
   if (last_name == "") last_name=name;
   if ((last_name != name) && (action==true)) display(last_name);
   if (document.all) 
   {
      var layerObj = eval("document.all." + name + ".style");
      var hide = "hidden";
      var show = "visible";
   }
   else
   {
      var layerObj = eval("document." + name);
      var hide = "hide";
      var show = "show";
   }
   layerObj.visibility = (action ?  hide : show);
   layerObj.position = (action ?  "absolute" : "relative");
   action = !action;
   last_name=name;
}

/*
Incorporate CSS Menu highlight capability - By Marc Boussard (marc.boussard@syntegra.fr)
Modified by DD for NS4 compatibility Visit http://www.dynamicdrive.com for this script
*/
var ns4class='';

var last_level;
function button(level,bname,page,tip,submenu)
{
   var button_name= bname + "_button";
   var gtype = ".png";
   var dir = "graphics/";
   var button_style=0;
   var style="menu" + level;

   if (last_level > level)
   {
     document.write ('</table>');
     document.write ('</div>');
     start_table();
   }
   if (submenu > 0)
   {
      document.write ('<tr><td class=' + style +'><a class=' + style + ' class=&{ns4class}; href=# title="' + tip +'"');
      document.write(' onClick=\'javascript:display("' + bname + '");\'');
      document.write('><img SRC="image/arrow.gif" width=18 height=9 border=0 valign=center align=right title="Click for more information"');
   }
   else
   {
      document.write ('<tr><td class=' + style +'><a class=' + style + ' class=&{ns4class}; href=' + page + ' title="' + tip +'"');
   }
   if (button_style >0)
   {
      document.write(' onMouseOver="document.' + button_name + ".src='" + dir + button_name + '1' + gtype + '\';"'); 
      document.write(' onMouseOut ="document.' + button_name + ".src='" + dir + button_name + gtype + '\';"'); 
      document.write('><img name=' + button_name + ' SRC="' + dir + button_name + gtype +'" width=100 height=30 border=0>');
   }
   else
   {
      document.write('>' + bname);
   }
   document.write('</a></td></tr>');

   if (submenu > 0)
   {
      document.write ('</table>');
      document.write ('<div id="' + bname + '" style="visibility:hidden; left:0px; height:20px; position:absolute">');
      start_table();
   }
   last_level=level;
}

function start_table()
{
   document.write ('<table summary=ph2 width=100% border=0 bgcolor=#ffffff cellspacing=1 cellpadding=5>');
}

function tag(tagname)
{
   document.write('>[' + tagname +']&nbsp;');
}

//////////////////////////////////////////////////
//
// IMAGE Rollover routines
// 
// Adapted from Javascript Application Cookbook (O'Reilly) - Chapter 6
//
/////////////////////////////////////////////////


function initialise_images()
{
   // Set image variables
   var imgPath 	= 'graphics/';
   var arrayHandles = new Array('_button', '_button1');

   // Dynamically create image arrays
   for (var i = 0; i < arrayHandles.length; i++) 
   {
      eval('var ' + arrayHandles[i] + ' = new Array()');
   }
   // Preload the images
   for (var i = 0; i < imgNames.length; i++)
   {
      imagePreLoad(imgNames[i], i);
   }
}

// Define a function to preload the images
function imagePreLoad(imgName, idx)
{
   for(var j = 0; j < arrayHandles.length; j++)
   {
      eval(arrayHandles[j] + "[" + idx + "] = new Image()");
      eval(arrayHandles[j] + "[" + idx + "].src = '" + imgPath + imgName + arrayHandles[j] + ".gif'");
   }
}

// Perform image rollover
function imageSwap(imagePrefix, imageIndex, arrayIdx)
{
   document[imagePrefix].src = eval(arrayHandles[arrayIdx] + "[" + imageIndex + "].src");
}



