Javascript Date padded2()

Description

Javascript Date padded2()


// Time Format as "17:00" in DropDown Box
Date.padded2 = function(hour) {
  padded2 = hour.toString();// w  ww .j  a  v a  2  s.c  om
  if ((parseInt(hour) < 10) || (parseInt(hour) == null))
    padded2 = "0" + padded2;
  return padded2;
}



PreviousNext

Related