﻿function ycqNet() {
}
//日期
ycqNet.prototype.today = function () {
    var _now = new Date;
    var _split = arguments[0] || "-";
    var _nowString = [];
    _nowString.push(_now.getFullYear());
    _nowString.push(_split);
    _nowString.push(_now.getMonth() + 1);
    _nowString.push(_split);
    _nowString.push(_now.getDate());
    return _nowString.join('');
};
ycqNet.prototype.chineseDate = function () {
var _now = new Date;
    var _nowString = [];
    _nowString.push("今天是：");
    _nowString.push(_now.getFullYear());
    _nowString.push("年");
    _nowString.push(_now.getMonth() + 1);
    _nowString.push("月");
    _nowString.push(_now.getDate());
    _nowString.push("日");
    return _nowString.join('');
};
//星期
ycqNet.prototype.week = function () {
    var _now = new Date;
    var _week = _now.getDay();
    switch (_week) {
        case 0: return "星期天";
        case 1: return "星期一";
        case 2: return "星期二";
        case 3: return "星期三";
        case 4: return "星期四";
        case 5: return "星期五";
        case 6: return "星期六";
    }
};
//日期+星期
ycqNet.prototype.todayAndWeek = function () {
    return this.today(arguments[0]) + "&#160;&#160;" + this.week();
};
ycqNet.prototype.chineseTodayAndWeek=function(){
    return this.chineseDate()+"&#160;&#160;" + this.week();
};
