﻿// Wedding Exhibitions Dublin - Main Site Legal Footer External JavaScript File by The IT Company @ www.theitcompany.ie

// Generate Current Date
    var now = new Date();
    var hours = now.getHours();
    var minutes = now.getMinutes();
    var timeValue = "" + ((hours >12) ? hours -12 :hours)
    timeValue += ((minutes < 10) ? ":0" : ":") + minutes
    timeValue += (hours >= 12) ? "pm" : " am"
    timerRunning = true;

    mydate = new Date();
    myday = mydate.getDay();
    mymonth = mydate.getMonth();
    myweekday= mydate.getDate();
    weekday= myweekday;
    myyear= mydate.getFullYear();
    year = myyear

    if(myday == 0)
             day = " Sun "      
    else if(myday == 1)
           day = " Mon "
    else if(myday == 2)
             day = " Tue "   
    else if(myday == 3)
             day = " Wed "   
    else if(myday == 4)
             day = " Thur "
    else if(myday == 5)
             day = " Fri "
    else if(myday == 6)
             day = " Sat "
    if(mymonth == 0)
              month = " January "
    else if(mymonth ==1)
              month = " February "
    else if(mymonth ==2)
             month = " March "
    else if(mymonth ==3)
            month = " April "
    else if(mymonth ==4)
              month = " May "
    else if(mymonth ==5)
              month = " June "
    else if(mymonth ==6)
              month = " July "
    else if(mymonth ==7)
            month = " August "
    else if(mymonth ==8)
           month = " September "
    else if(mymonth ==9)
          month = " October "
    else if(mymonth ==10)
          month = " November "
    else if(mymonth ==11)
          month = " December "

function MakeArrayday(size) {
this.length = size;
for(var i = 1; i <= size; i++) {
this[i] = "";
}
return this;
}
function MakeArraymonth(size) {
this.length = size;
for(var i = 1; i <= size; i++) {
this[i] = "";
}
return this;
}
function funClock() {
if (!document.layers && !document.all)
return;
var runTime = new Date();
var hours = runTime.getHours();
var minutes = runTime.getMinutes();
var seconds = runTime.getSeconds();
var dn = "am";
if (hours >= 12) {
dn = "pm";
hours = hours - 12;
}
if (hours == 0) {
hours = 12;
}
if (minutes <= 9) {
minutes = "0" + minutes;
}
if (seconds <= 9) {
seconds = "0" + seconds;
}
// movingtime = hours + ":" + minutes + ":" + seconds + " " + dn; // ORIGINAL WITH SECONDS
movingtime = hours + ":" + minutes + " " + dn;
if (document.layers) {
document.layers.clock.document.write(movingtime);
document.layers.clock.document.close();
}
else if (document.all) {
clock.innerHTML = movingtime;
}
setTimeout("funClock()", 1000)
}
window.onload = funClock;

document.write('<p>');
document.write('<img alt="Wedding Exhibitions Dublin" src="images/wed-logo.gif" width="161" height="71" style="float: right" />Telephone: +353 (1) 4901405, Fax: +353 (1) 4906529.<br/>');
document.write('Registered Office: Anton House, 184 Rathfarnham Road, Dublin 14, Ireland - Registered No: 350616.<br />');
document.write('The name The Wedding &amp; Honeymoon Show and the Logo are registered trademarks of WED.<br/>');
document.write(day + myweekday + month +" "+ myyear + " @ ");
document.write('<span id="clock" style="position:relative;"></span>. ');
document.write('<img alt="Wedding Exhibitions Dublin" src="images/official-logos.jpg" width="161" height="54" style="float: right" />Wedding Exhibitions Dublin &copy; 1989 - ' + myyear + '.<br>All rights Reserved.<br>');
