Javascript Date color()
color()
Date.prototype.color = function(){ return {//w w w. j a va2 s . c om 0: 'yellow', 1: 'red', 2: 'orange', 3: 'purple', 4: 'cyan', 5: 'blue', 6: 'green' }[this.getDay()] }