Get AMPM hour - Node.js Date

Node.js examples for Date:Hour

Description

Get AMPM hour

Demo Code

Date.prototype.getAMPMHour = function() { 
     hour=Date.padded2(this.getHours()); 
     return (hour == null) ? 00 : (hour > 24 ? hour - 24 : hour );
}

Related Tutorials