var old_calendar='January 26';
var new_calendar='February 8';
var x_year='2010';
var ad_creatio='7518';
var n_day='26';
var n_month='1';
var w_day='Monday';
var m_saints='\<A\ Href\=\"JavaScript\:openWindow\(\'http\:\/\/www\.ponomar\.net\/typicon\.html\'\)\;\"\>\<IMG\ Src\=\"http\:\/\/www\.ponomar\.net\/images\/T1\.gif\"\ Alt\=\"A\ service\ with\ no\ mark\ in\ the\ Typicon\ is\ served\ for\ this\ saint\"\ Border\=\"0\"\>\<\/A\>\<A\ Href\=\"JavaScript\:doSaints\(\'312\'\)\;\"\>Venerable\ Xenophontes\ with\ his\ wife\ Maria\,\ and\ their\ sons\ Arkadius\ and\ John\ of\ Constantinople\ \(5th\-6th\ C\)\<\/A\>\;\ \<A\ Href\=\"JavaScript\:doSaints\(\'390\'\)\;\"\>Saint\ Simeon\ the\ Old\ of\ Mt\ Sinai\ \(\+c\.390\)\<\/A\>\;\ \<A\ Href\=\"JavaScript\:doSaints\(\'314\'\)\;\"\>Martyrs\ Ananias\ the\ Presbyter\,\ Peter\ the\ Prison\ Guard\ and\ 7\ prison\ guards\ \(\+295\)\<\/A\>\;\ \<A\ Href\=\"JavaScript\:doSaints\(\'2202\'\)\;\"\>Translation\ of\ the\ relics\ of\ Venerable\ Theodore\,\ Abbot\ of\ the\ Studion\ Monastery\ \(845\)\<\/A\>\;\ \<A\ Href\=\"JavaScript\:doSaints\(\'317\'\)\;\"\>Saint\ Joseph\,\ Archbishop\ of\ Thessalonica\,\ brother\ of\ St\.\ Theodore\ of\ Studion\ \(\+830\)\<\/A\>\;\ Venerable\ Gabriel\,\ Abbot\ of\ Jerusalem\;\ \<A\ Href\=\"JavaScript\:doSaints\(\'318\'\)\;\"\>Blessed\ David\ III\ the\ Restorer\,\ King\ of\ Iberia\ \(Georgia\)\ \(\+1125\)\<\/A\>\;\ ';
var paschalcycle='Cheesefare\ Monday\;\ Tone\:\ II\;\ ';
var readings='\<B\>apostol\<\/B\>\:\ \<A\ Href\=\"JavaScript\:doReadings\(\'III\ Jn\'\,\ \'1\:1\-15\'\)\"\>III\ Jn\ 1\:1\-15\<\/A\>\&nbsp\;\<B\>gospel\<\/B\>\:\ \<A\ Href\=\"JavaScript\:doReadings\(\'Lk\'\,\ \'19\:29\-40\,\ 22\:7\-39\'\)\"\>Lk\ 19\:29\-40\,\ 22\:7\-39\<\/A\>\&nbsp\;';
var fastinfo='Fast: No meat products';

function doSaintsLink()
{
	url = 'http://www.ponomar.net/cgi-bin/index.cgi';
	//e.g. http://www.oca.org/FSlives.asp?SID=4&M=5&D=7
	window.open(url, 'nWindow', 'height=500,width=800,scrollbars=yes,resizable=yes');
}

function doReadings(book, chapter) {
	// LAUNCH LECTIONARY 1.0
	var url = 'http://www.ponomar.net/cgi-bin/bible.cgi?mode=specify&LS=0&book=' + book + '&reading=' + chapter;
	window.open(url, 'bible', 'height=500,width=900,scrollbars=yes,resizable=yes');
}

function printDateDefault()
{
	document.write(w_day + ', ' + old_calendar + ' ' + x_year + ' (' + ad_creatio + ')');
}

function printDateNS()
{
	document.write('&nbsp;[' + new_calendar + ' on the civil calendar]');
}

function printPaschalCycle()
{
	document.write('<B>' + paschalcycle + '</B> ');
}

function printSaints()
{
	document.write(m_saints);
}

function printReadings()
{
	document.write(readings);
}

function printIcon()
{
	document.write('<img src="http://www.ponomar.net/cgi-bin/cache.cgi">');
}

function doPrologue(month, day) {
	var nmonth = new Number(month);

	var mths = new Array("January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December");
	var prolUrl = 'day=' + day + '&month=' + mths[nmonth];
	window.open('http://www.westsrbdio.org/prolog/my.html?' + prolUrl, 'nPrologue', 'height=500,width=800,scrollbars=yes,resizable=yes');
}

function doLink()
{
	window.open('http://www.ponomar.net/cgi-bin/index.cgi', 'nHelp', 'height=500,width=800,scrollbars=yes,resizable=yes');
}

function doSaints(id)
{
	var url = 'http://www.ponomar.net/cgi-bin/lives.cgi?id=' + id;
	window.open(url, 'life' + id, 'height=600,width=800,scrollbars=yes,resizable=yes');
}

function openWindow(url)
{
	window.open(url, "mailer", "scrollbars=1, height=600, left=150, top=150, width=500");
}

document.write('<div class="saints"><b>Today is:</b> '); printDateDefault(); printDateNS(); document.write('<br>Today the Church celebrates:<BR><BR>');printPaschalCycle(); printSaints(); document.write('<br><b>Fasting:</b> ' + fastinfo + ' <b>Scripture Reading: </b>');printReadings(); document.write('<br><small>Powered by Ponomar. <A Href="JavaScript:doLink();">Complete online menologion</A>.</small></div>');