﻿// JavaScript Document
function date_int(TheFontColor)
{
var TheFontFace  = "Arial";
var TheFontSize  = "1";
var TheFontStyle = "bold"; 

// Set the separator between the date elements;
// usually use either - or /.

var TheSeparator = " ";

// Show or do not show the day of the week; set
// yes to show, no not to show.

var ShowDay ="yes";

// Do Not Edit Below This Line
// ==============================================

//var Days = new Array("Chủ Nhật ","Thứ Hai ","Thứ Ba ","Thứ Tư ","Thứ Năm ","Thứ Sáu ","Thứ Bảy ");
var Days = new Array("Sunday ","Monday ","Tuesday ","Wednesday ","Thursday ","Friday ","Saturday ");
var Months = new Array("January ","February","March","April","May","June","July","August","September ","October ","November ","December ");
var TheDate = new Date();

var TheWeekDay = TheDate.getDay();
var Day ="";
if (ShowDay == "yes"){
    Day = Days[TheWeekDay];
    Day += " ";}

var TheMonth = TheDate.getMonth() + 1;

//if (TheMonth < 10) TheMonth = "0" + TheMonth;
var valueMonth = TheMonth - 1;
TheMonth = Months[valueMonth];

var TheMonthDay = TheDate.getDate();
if (TheMonthDay < 10) TheMonthDay = "0" + TheMonthDay;

var TheYear = TheDate.getYear();
if (TheYear < 1000) TheYear += 1900;

var FontTagLeft  = "";
var FontTagRight = "";

if (TheFontStyle == "bold"){
    FontTagLeft = "<b>";
    FontTagRight ="</b>";}
    
if (TheFontStyle == "italic"){
    FontTagLeft = "<i>";
    FontTagRight ="</i>";}
    
if (TheFontStyle == "bolditalic"){
    FontTagLeft = "<b><i>"; 
    FontTagRight = "</i></b>";}    

var D = "";
D += "<font color='"+TheFontColor+"' face='"+TheFontFace+"' size='"+TheFontSize+"'>";
D += FontTagLeft+Day+", "+TheMonth+TheSeparator+TheMonthDay+TheSeparator+TheYear+FontTagRight;
D += "</font>";

document.write(D);
//-->
}
