<!--
var citycode='AAA';var lang='en';var xvar=document.referrer;if (xvar.indexOf("britinfo.net")>0){var sp=xvar.indexOf("cc=");if (sp>0){citycode=xvar.substring(sp+3,sp+6);}sp=xvar.indexOf("l=");if (sp>0){lang=xvar.substring(sp+2,sp+4) ;}}
var MapWindow=null;function stopErrors(){return true;}function map(postcode)
{var mapurl='http://www.streetmap.co.uk/streetmap.dll?P2M?P='+postcode+'&Z=1';var whichmap=postcode.substring(0,2);
if (whichmap=='BT' || whichmap=='JE') mapurl='http://www.multimap.com/map/browse.cgi?client=public&db=GB&cname=Great+Britain&pc='+postcode
if (MapWindow==null || MapWindow.closed)MapWindow=window.open(mapurl,'map','width=500,height=400,directories=no,location=no,menubar=no,scrollbars=yes,status=yes,toolbar=no,resizable=yes');MapWindow.onerror=stopErrors;MapWindow.focus();}

var commandparams='';
//var commandparams=GetCookie('commandparams') ;
var cpvehicles=GetCookie('cpvehicles') ;
var cpcinema=GetCookie('cpcinema') ;
var cptheatre=GetCookie('cptheatre') ;
var cpevents=GetCookie('cpevents') ;

function footer()
{
document.write('<BR><HR color="#000080"><P><center><ADDRESS><FONT size="+1">&copy;</FONT> 2000-2006 Electronic Mind Ltd.&nbsp;&nbsp;All rights reserved.<br><a href="../index.htm" target="_top">www.britinfo.net</a> &nbsp;&nbsp;&nbsp;<a href="/cgi-bin/ins.cgi?ss=advertising&cc='+citycode+'&l=en&s=A&f=contact&fromip=1" target="_top">Cont@ct us</a><br></ADDRESS><P></center>') ;
var cdate = new Date();xr=cdate.getYear()+'_'+cdate.getMonth()+'_'+cdate.getDate();
//document.write('<img border=0 src="/cgi-bin/counters/count.cgi?id=ips&ref='+escape(document.referrer)+'&r='+xr+'" width=1 height=1>') ;
}
var temp1='<TR valign="top"><TD><img src="../images/icons/';var temp2='.gif" width=40 height=40 border=0';var temp2a='"></TD><TD>';var temp3='</a></TD></TR>';

google_ad_client = "pub-1630406215990884";
google_ad_width = 120;
google_ad_height = 600;
google_ad_format = "120x600_as";
google_ad_type = "text";
google_ad_channel ="1098012384";
google_color_border = "FFFFFF";
google_color_bg = "FBFBF0";
google_color_link = "000000";
google_color_url = "000080";
google_color_text = "000000";

function replace_strings(s,char1,char2){return s.replace(char1,char2);}
function p_row(em_type,em_id,em_etc)
{
if (em_type==1){em_grname='cintimes';em_alttag='cinema times, listings';em_prog='Nfilmlist';em_des='View cinema listings.';commandparams=cpcinema}
if (em_type==2){em_grname='showtimes';em_alttag='show, theatre times';em_prog='Nshowlist';em_des='View performance times.';commandparams=cptheatre}
if (em_type==3){em_grname='events';em_alttag='diary of events';em_prog='Elist';em_des='View events listings.'}
if (em_type==4)
{
   em_grname='motorshowrooms';em_alttag='car adverts';em_prog='Ilist';em_des='View adverts';commandparams=cpvehicles;
   if (cpvehicles){document.write(temp1+em_grname+temp2+' alt="'+em_alttag+temp2a+'<a href="/cars/vehicles-'+em_id+'.htm" target="_top">'+em_des+temp3) ;return;}
}

//if (cpcinema && em_type==1){document.write(temp1+em_grname+temp2+' alt="'+em_alttag+temp2a+'<a href="/cinema/cinema-listings-'+em_id+'.htm" target="_top">'+em_des+temp3) ;return;}
//if (cptheatre && em_type==2){document.write(temp1+em_grname+temp2+' alt="'+em_alttag+temp2a+'<a href="/theatre/theatre-listing-'+em_id+'.htm" target="_top">'+em_des+temp3) ;return;}
if (em_type==1){document.write(temp1+em_grname+temp2+' alt="'+em_alttag+temp2a+'<a href="/cinema/cinema-listings-'+em_id+'.htm" target="_top">'+em_des+temp3) ;return;}
if (em_type==2){document.write(temp1+em_grname+temp2+' alt="'+em_alttag+temp2a+'<a href="/theatre/theatre-listing-'+em_id+'.htm" target="_top">'+em_des+temp3) ;return;}
if ((cpevents ||cptheatre) && em_type==3){var a=em_etc.length;var b=a-7;var sitecode=em_etc.substring(a,b);document.write(temp1+em_grname+temp2+' alt="'+em_alttag+temp2a+'<a href="/events/events-'+sitecode+'.htm" target="_top">'+em_des+temp3) ;return;}
document.write(temp1+em_grname+temp2+' alt="'+em_alttag+temp2a+'<a href="/cgi-bin/'+em_prog+'.cgi?idnum='+em_id+'&cc='+citycode+'&l='+lang+em_etc+commandparams+'" target="_top">'+em_des+temp3) ;
}
function p_row2(em_type,em_id)
{
if (em_type==7){em_grname='bookroom';em_alttag='Booking/Check availability';em_prog='go';em_des='Check availability / Booking'}
document.write(temp1+em_grname+temp2+' alt="'+em_alttag+temp2a+'<a href="/cgi-bin/accombook.cgi?idnum='+em_id+'" target="_top">'+em_des+temp3) ;
}
function p_email(em_address){document.write('<TR valign="top"><TD><img src="../images/icons/at.gif" width=40 height=40 border=0 alt="Send Email"></TD><TD><a href="mailto:'+em_address+'?subject=Generated from http://www.britinfo.net">'+em_address+'</a></TD></TR>');}
function p_link(em_address)
{
if (em_address.indexOf('chooseacottage.co.uk',0) >0) // temporary fix for cottages
{
   em_address=replace_strings(em_address,"%3f","?") ;
   em_address=replace_strings(em_address,"%26","&") ;
}
document.write('<TR valign="top"><TD><img src="../images/icons/web.gif" width=40 height=40 border=0 alt="Web site"></TD><TD><a href="http://'+em_address+'" target="externalsite">Web site</a></TD></TR>');
}



function urlgo(em_address){em_address = em_address.replace(/\/bookings\/BIN/ig, "&trkref=BIN&subid=britinfo");
var urlstring='';var xx=em_address.indexOf('-',0);
//if (em_address.indexOf('http://',0) == -1) urlstring='http://';
//var xyiyiy=em_address.indexOf('http://',0);
//alert(xyiyiy) ;
if (em_address.indexOf('http://',0) !=0) urlstring='http://'; // only put http at front if none at position zero
//if ((em_address.indexOf('www.',0) == -1) && (xx != 0) ) urlstring=urlstring+'www.';
var xy=em_address.indexOf('www.',0) ;if (((xy == -1)|| (xy >10)) && (xx != 0) ) urlstring=urlstring+'www.';
if ((xx == 0) ) em_address=em_address.substr(1);
urlstring=urlstring+em_address ;
if (em_address.indexOf('chooseacottage.co.uk',0) >0) // temporary fix for cottages
{
   em_address=replace_strings(em_address,"%3f","?") ;
   em_address=replace_strings(em_address,"%26","&") ;
}
window.open(urlstring);
}

function mmm(em_address)
{
   em_address=replace_strings(em_address,"#~#","@") ;
   document.write('<a href="mailto:'+em_address+'?subject=Generated from http://www.britinfo.net">'+em_address+'</a>') ;
}

function actionbar(buttonstring)
{
   var em_type,em_id,em_etc,bslen,recordindex,recordend,recordstr,recordindex,fieldend,fieldstr,recordcount,count,i ;
   document.write('<br><br><TABLE CELLSPACING="0" CELLPADDING="8" border="1" width="100%" bordercolor="#000000"><TR><TD>') ;

   bslen = buttonstring.length;
   recordindex = 0;
   recordcount=0 ;
   var docase=0 ;
   while (recordindex < bslen)
   {
      recordend = buttonstring.indexOf ("|", recordindex);
      if (recordend == -1) recordend = bslen;
      recordstr=buttonstring.substring(recordindex, recordend);recordcount=recordcount+1 ;
      if (recordcount == 1)
      {em_id=recordstr ;}
      else
      {
         var clen = recordstr.length;
         if (clen>0) // skip blank records
         {
            i = 0;count=0 ;em_etc='' ;
            while (i < clen && count <3)
            {
               count=count+1 ;fieldend = recordstr.indexOf ("~", i);
               if (fieldend == -1) fieldend = clen;
               fieldstr=recordstr.substring(i, fieldend);
               if (count == 1) em_type = fieldstr;
               if (count == 2) em_etc = fieldstr;
               i = fieldend + 1;
            }
            //the first four are the same as the main ones
            if (em_type==1){em_grname='cintimes';em_alttag='cinema times, listings';em_prog='Nfilmlist';em_des='View cinema listings.';commandparams=cpcinema}
            if (em_type==2){em_grname='showtimes';em_alttag='show, theatre times';em_prog='Nshowlist';em_des='View performance times.';commandparams=cptheatre}
            if (em_type==3){em_grname='events';em_alttag='diary of events';em_prog='Elist';em_des='View events listings.'}
            if (em_type==4){em_grname='motorshowrooms';em_alttag='car adverts';em_prog='Ilist';em_des='View adverts';em_etc='&com=viewsite';commandparams=cpvehicles}
            if (em_type==5){em_grname='u04';em_alttag='';em_prog='booktickets';em_des='Book Tickets'}
            if (em_type==6){em_grname='u04';em_alttag='';em_prog='';em_des='Book Tickets'} // this is for the one going direct to URL
            if (em_type==7){em_grname='bookroom';em_alttag='';em_prog='accombook';em_des='Book a room'} 
            if (em_type==8){em_grname='u12';em_alttag='';em_prog='ins';em_des='Add your own entry in the directory';em_etc='&s=T&f=T1'}
            if (em_type==9){em_grname='u02';em_alttag='';em_prog='';em_des='Send to my mobile'}
            if (em_type==10){em_grname='u13';em_alttag='Local search:Pubs, restaurants, etc.';em_prog='findlocal2';em_des='Local search:Pubs, restaurants, etc.';commandparams=''; em_etc=em_etc+'&a=1';}
            //if (em_type==4){em_grname='';em_alttag='';em_prog='';em_des=''}
            if (em_prog=='')
            {
               document.write('<a href="javascript:urlgo(\''+em_etc+'\')">') ;
            }
            else
            {
               docase=0 ;
               if (em_type==1) //cpcinema && 
               {
                  document.write('<a href="/cinema/cinema-listings-'+em_id+'.htm" target="_top">') ;
                  docase=1 ;
               }
               if (em_type==2) //cptheatre && 
               {
                  document.write('<a href="/theatre/theatre-listing-'+em_id+'.htm" target="_top">') ;
                  docase=1 ;
               }
               if ((cpevents ||cptheatre) && em_type==3)
               {
                  document.write('<a href="/events/events-'+em_id+'.htm" target="_top">') ;
                  docase=1 ;
               }
               if (cpvehicles && em_type==4)
               {
                  document.write('<a href="/cars/vehicles-'+em_id+'.htm" target="_top">') ;
                  docase=1 ;
               }
               if (docase<1)
               {
                  document.write('<a href="/cgi-bin/'+em_prog+'.cgi?idnum='+em_id+'&cc='+citycode+'&l='+lang+em_etc+commandparams+'" target="_top">') ;
               }
            }
            document.write('<img src="../images/icons/'+em_grname+'.gif" width=40 height=40 border=0'+' alt="'+em_des+'"></a>&nbsp;&nbsp;') ;
         }
      }
      recordindex = recordend + 1;
   }
   document.write('</TD></TR></TABLE>\n') ;
}


function eventredirect(em_id)
{
   var myurl='';
   if (cpevents ||cptheatre)
   {
      myurl='events/events-'+em_id+'.htm' ;
   }
   else
   {
      myurl='cgi-bin/Elist.cgi?cc='+citycode+'&l='+lang+'&com=viewsite&sc='+em_id ;
   }
   myurl='http://www.britinfo.net/'+myurl ;window.location=myurl ;
}

<!-- These bits deal with cookies -->
var expDays = 365; // number of days the cookie should last

function GetCookie (name) {  
//alert('!'+document.cookie+'!!!!') ;
//alert('!'+name+'!') ;
var arg = name + "=";  
var alen = arg.length;  
var clen = document.cookie.length;  
var i = 0;  
while (i < clen) {    
var j = i + alen;    
if (document.cookie.substring(i, j) == arg)      
return getCookieVal (j);    
i = document.cookie.indexOf(" ", i) + 1;    
if (i == 0) break;   
}  
return '';
}
function SetCookie (name, value) {  
//alert(name+' '+value) ;
var argv = SetCookie.arguments;  
var argc = SetCookie.arguments.length;  
var expires = (argc > 2) ? argv[2] : null;  
var path = (argc > 3) ? argv[3] : null;  
var domain = (argc > 4) ? argv[4] : null;  
var secure = (argc > 5) ? argv[5] : false;  
document.cookie = name + "=" + escape (value) + 
((expires == null) ? "" : ("; expires=" + expires.toGMTString())) + 
((path == null) ? "" : ("; path=" + path)) +  
((domain == null) ? "" : ("; domain=" + domain)) +    
((secure == true) ? "; secure" : "");
}
function DeleteCookie (name) {  
var exp = new Date();  
exp.setTime (exp.getTime() - 1);  
var cval = GetCookie (name);  
document.cookie = name + "=" + cval + "; expires=" + exp.toGMTString();
}
var exp = new Date(); 
exp.setTime(exp.getTime() + (expDays*24*60*60*1000));
function amt(){
var count = GetCookie('count')
if(count == null) {
SetCookie('count','1')
return 1
}
else {
var newcount = parseInt(count) + 1;
DeleteCookie('count')
SetCookie('count',newcount,exp)
return count
   }
}
function getCookieVal(offset) {
//alert(offset+'=') ;
var endstr = document.cookie.indexOf (";", offset);
if (endstr == -1)
endstr = document.cookie.length;
return unescape(document.cookie.substring(offset, endstr));
}
function SetexpDays(expDaysval){expDays=expDaysval}
// -->
