function formatTimem() {
  now = new Date();
  hour = now.getHours();
  min = now.getMinutes();
  sec = now.getSeconds();


    if (min <= 9) {
      min = "0" + min;
    }
    if (sec <= 9) {
      sec = "0" + sec;
    }
    if (hour > 12) {
      hour = hour - 12;
      add = " P.M.";
    } else {
      hour = hour;
      add = " A.M.";
    }
    if (hour == 12) {
      add = " P.M.";
    }
    if (hour == 00) {
      hour = "12";
    }

    document.clock_mumbai.mumbai.value = ((hour<=9) ? "0" + hour : hour) + ":" + min + ":" + sec + add;
 
	
 nowd = new Date() ;
 

  secd = now.getSeconds();
  mind = now.getMinutes() - 30 ;

  hourd = now.getHours() - 1;


if (mind < 0) mind += 60, hourd=hourd-1;

    if (mind <= 9) {
      mind = "0" + mind;
    }
    if (secd <= 9) {
      secd = "0" + secd;
    }
    if (hourd > 12) {
      hourd = hourd - 12;
      add = " P.M.";
    } else {
      hourd = hourd;
      add = " A.M.";
    }
    if (hourd == 12) {
      add = " P.M.";
    }
    if (hourd == 00) {
      hourd = "12";
    }

    document.clock_dubai.dubai.value = ((hourd<=9) ? "0" + hourd : hourd) + ":" + mind + ":" + secd + add;
 

 nowd = new Date() ;
 

  secl = now.getSeconds();
  minl = now.getMinutes() - 30 ;

  hourl = now.getHours() - 5;


if (minl < 0) minl += 60, hourl=hourl-1;

    if (minl <= 9) {
      minl = "0" + minl;
    }
    if (secl <= 9) {
      secl = "0" + secl;
    }
    if (hourl > 12) {
      hourl = hourl - 12;
      add = " P.M.";
    } else {
      hourl = hourl;
      add = " A.M.";
    }
    if (hourl == 12) {
      add = " P.M.";
    }
    if (hourl == 00) {
      hourl = "12";
    }

    document.clock_london.london.value = ((hourl<=9) ? "0" + hourl : hourl) + ":" + minl + ":" + secl + add;
 

 nowd = new Date() ;
 

  secn = now.getSeconds();
  minn = now.getMinutes() - 30 ;

  hourn = now.getHours() - 9;


if (minn < 0) minn += 60, hourn=hourn-1;

    if (minn <= 9) {
      minn = "0" + minn;
    }
    if (secn <= 9) {
      secn = "0" + secn;
    }
    if (hourn > 12) {
      hourn = hourn - 12;
      add = " P.M.";
    } else {
      hourn = hourn;
      add = " A.M.";
    }
    if (hourn == 12) {
      add = " P.M.";
    }
    if (hourn == 00) {
      hourn = "12";
    }

    document.clock_ny.ny.value = ((hourn<=9) ? "0" + hourn : hourn) + ":" + minn + ":" + secn + add;
 



 nowd = new Date() ;
 

  secs = now.getSeconds();
  mins = now.getMinutes() + 30 ;

  hours = now.getHours() + 2;

if (mins > 59) mins -= 60, hours=hours+1;
if (mins < 0) mins += 60, hours=hours-1;

    if (mins <= 9) {
      mins = "0" + mins;
    }
    if (secs <= 9) {
      secs = "0" + secs;
    }
    if (hours > 12) {
      hours = hours - 12;
      add = " P.M.";
    } else {
      hours = hours;
      add = " A.M.";
    }
    if (hours == 12) {
      add = " P.M.";
    }
    if (hours == 00) {
      hours = "12";
    }

    document.clock_sp.sp.value = ((hours<=9) ? "0" + hours : hours) + ":" + mins + ":" + secs + add;
 



 nowd = new Date() ;
 

  sect = now.getSeconds();
  mint = now.getMinutes() + 30 ;

  hourt = now.getHours() + 3;

if (mint > 59) mint -= 60, hourt=hourt+1;
if (mint < 0) mint += 60, hourt=hourt-1;

    if (mint <= 9) {
      mint = "0" + mint;
    }
    if (sect <= 9) {
      sect = "0" + sect;
    }
    if (hourt > 12) {
      hourt = hourt - 12;
      add = " P.M.";
    } else {
      hourt = hourt;
      add = " A.M.";
    }
    if (hourt == 12) {
      add = " P.M.";
    }
    if (hourt == 00) {
      hourt = "12";
    }

    document.clock_tk.tk.value = ((hourt<=9) ? "0" + hourt : hourt) + ":" + mint + ":" + sect + add;
 



  setTimeout("formatTimem()", 1000);
}

window.onload=formatTimem;

