User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the JavaScript / DHTML / AJAX section within the Web Development category of DaniWeb, a massive community of 427,306 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,753 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our JavaScript / DHTML / AJAX advertiser: Lunarpages Web Hosting

DateTime - TimeZone conversion with Javascript. Partially working!

Join Date: Aug 2006
Location: India
Posts: 4
Reputation: Gravis is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
Gravis Gravis is offline Offline
Newbie Poster

Re: DateTime - TimeZone conversion with Javascript. Partially working!

  #2  
Aug 28th, 2006
Ok, I resolved this myself. I had to change the code down below to this...
var hour = time.getHours() ;
  var minute = time.getMinutes();
  var curTime = date+" "+GetMonth(time.getMonth())+" ";
  if(hour==0) { hour = "12";}
  curTime += ((hour > 12) ? hour - 12 : hour);
  curTime += ((minute < 10) ? ":0" : ":") + minute;
  curTime += (hour >= 12) ? " PM" : " AM";
Reply With Quote  
All times are GMT -4. The time now is 2:23 am.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC