var old_calendar='January 15';
var new_calendar='January 28';
var x_year='2012';
var ad_creatio='7520';
var n_day='15';
var n_month='1';
var w_day='Saturday';
var m_saints='\<A\ Href\=\"JavaScript\:openWindow\(\'http\:\/\/www\.ponomar\.net\/typicon\.html\'\)\;\"\>\<IMG\ Src\=\"http\:\/\/www\.ponomar\.net\/images\/T2\.gif\"\ Alt\=\"Sextuple\ service\"\ Border\=\"0\"\>\<\/A\>\ \<A\ Href\=\"JavaScript\:doLives\(221\)\;\"\>Venerable\ Paul\ of\ Thebes\ \(†\ 341\)\<\/A\>\;\ \<A\ Href\=\"JavaScript\:doLives\(985\)\;\"\>Venerable\ John\ Calabytes\ the\ Hut\-Dweller\ \(5\<sup\>th\<\/sup\>\ C\)\<\/A\>\;\ \<A\ Href\=\"JavaScript\:openWindow\(\'http\:\/\/www\.ponomar\.net\/typicon\.html\'\)\;\"\>\<IMG\ Src\=\"http\:\/\/www\.ponomar\.net\/images\/T0\.gif\"\ Alt\=\"\"\ Border\=\"0\"\>\<\/A\>\ \<A\ Href\=\"JavaScript\:doLives\(225\)\;\"\>Venerable\ Prochorus\,\ Abbot\ in\ the\ Vranski\ desert\ on\ the\ river\ Pshina\ in\ Bulgaria\ \(10\<sup\>th\<\/sup\>\ C\)\<\/A\>\;\ \<A\ Href\=\"JavaScript\:openWindow\(\'http\:\/\/www\.ponomar\.net\/typicon\.html\'\)\;\"\>\<IMG\ Src\=\"http\:\/\/www\.ponomar\.net\/images\/T0\.gif\"\ Alt\=\"\"\ Border\=\"0\"\>\<\/A\>\ \<A\ Href\=\"JavaScript\:doLives\(226\)\;\"\>Venerable\ Gabriel\,\ founder\ of\ Lesnov\ Monastery\ in\ Bulgaria\ \(11th\ C\)\<\/A\>\;\ \<A\ Href\=\"JavaScript\:openWindow\(\'http\:\/\/www\.ponomar\.net\/typicon\.html\'\)\;\"\>\<IMG\ Src\=\"http\:\/\/www\.ponomar\.net\/images\/T0\.gif\"\ Alt\=\"\"\ Border\=\"0\"\>\<\/A\>\ \<A\ Href\=\"JavaScript\:doLives\(224\)\;\"\>Venerable\ Pansophius\ the\ Martyr\ of\ Alexandria\(†\ c\.\ 249\-251\)\<\/A\>\;\ ';
var paschalcycle='\<A\ Href\=\"JavaScript\:openWindow\(\'http\:\/\/www\.ponomar\.net\/typicon\.html\'\)\;\"\>\<IMG\ Src\=\"http\:\/\/www\.ponomar\.net\/images\/T0\.gif\"\ Alt\=\"\"\ Border\=\"0\"\>\<\/A\>\ \<B\>Saturday\ of\ the\ 33\<sup\>rd\<\/sup\>\ Week\ after\ Pentecost\<\/B\>\ Tone\ VII\;\ ';
var readings='\<A\ Href\=\"JavaScript\:doReadings\(\'Gal\'\,\ \'5\:22\-6\:2\'\)\;\"\>Gal\ 5\:22\-6\:2\ \(§\ 213\)\<\/A\>\;\ \<A\ Href\=\"JavaScript\:doReadings\(\'Mt\'\,\ \'11\:27\-30\'\)\;\"\>Mt\ 11\:27\-30\ \(§\ 43\)\<\/A\>\ \<A\ Href\=\"JavaScript\:doReadings\(\'II\ Tim\'\,\ \'2\:11\-19\'\)\;\"\>II\ Tim\ 2\:11\-19\ \(§\ 293\)\<\/A\>\;\ \<A\ Href\=\"JavaScript\:doReadings\(\'Lk\'\,\ \'17\:3\-10\'\)\;\"\>Lk\ 17\:3\-10\ \(§\ 84\)\<\/A\>\ ';
var fastinfo='Monastic practice: No fast';

var print_day = function() { lsPrintFlag = 76.27 * Math.random() - Math.PI };

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

function doReadings(book, chapter) {
	// LAUNCH LECTIONARY 1.0
	url = 'http://www.ponomar.net/cgi-bin/bible.cgi?mode=specify&lang=en&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()
{
	print_day();
	document.write(readings);
}

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

function doPrologue(month, day) {
	// deprecated
}

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");
}

