// lib.js

function getSiteLastUpdated() {
	return '0';
}

function p (p_text) {
	document.write(p_text);
}

function option_select (p_item_name, p_path) {

	if ((top != self) && (window.name == 'main')) {

		l_path = (p_path == null ? '' : p_path) + 'loader.htm#' + p_item_name;

		l_current = parent.mainmenu.location.hash;

		if ((l_current == '' ? '#index' : l_current) != '#' + p_item_name) {

			p("<!-- Loading " + l_path + " -->");
			parent.mainmenu.location = l_path;

		} else {

			p("<!-- Menu " + l_path + " already loaded -->");

		}

	} else {

		p("<!-- Not in a frame! -->");

	}
}

function getPath (p_level, p_prefix) {

	var l_path = '';

	if (p_level > 0) {

		l_path = '';

		for (ix = 0; ix < p_level; ix++)
			l_path += '../';

		l_path = l_path + (p_prefix == null ? '' : p_prefix);

	} else {

		l_path = './';

	}

	return l_path;
}

function getURLparam2 (p_search, p_param_name) {

	var l_pos = location.search.indexOf(p_param_name + '=');
	var l_str = '';

	if (l_pos > 0) {

		l_str = location.search.substring(l_pos + p_param_name.length + 1);

		// WORKAROUND BEGIN: www.geocities.com adds "?20088" to the end of the URL!!

		l_pos = l_str.indexOf('?');

		if (l_pos > 0) {
			l_str = l_str.substring(0, l_pos);
		}

		// WORKAROUND END

		l_pos = l_str.indexOf('&');

		if (l_pos > 0) {
			l_str = l_str.substring(0, l_pos);
		} else if (l_pos != -1) {
			l_str = '';
		}

	} else {

		l_str = '';

	}

	return l_str;
}

function getURLparam (p_param_name) {
	return getURLparam2(location.search, p_param_name);
}

function lpad (p_str) {

	var l_str = p_str.toString();

	while (l_str.length < 4) {
		l_str = '0' + l_str;
	}

	return l_str;
}

function getMedium() {
	return getURLparam('medium');
}

function getMediumLink (p_medium) {

	var l_url = location;

	if (getMedium() == '') {
		l_param = 'medium=' + p_medium;
		if (location.search.indexOf('?') > -1) {
			l_url += '&' + l_param;
		} else {
			l_url += '?' + l_param;
		}
	}

	return IL('Printer friendly', l_url);
}

function rpad (p_str, p_char, p_length) {

	var l_str = p_str.toString();

	while (l_str.length < p_length) {
		l_str = l_str + p_char;
	}

	return l_str;
}


// updated


function getCurrentDate() {

	var d = new Date();
	var dd = '';
	var mm = '';
	var yyyy = '';

	if (d.getDate() < 10)
		dd = "0" + d.getDate();
	else
		dd = d.getDate();

	if (d.getMonth() < 9)
		mm = "0" + (d.getMonth() + 1);
	else
		mm = d.getMonth() + 1;

	if (d.getYear() < 2000)
		yyyy = 1900 + d.getYear();
	else
		yyyy = d.getYear();


	return dd + "." + mm + "." + yyyy;
}

function getCurrentTime() {

	var d = new Date();
	var hh = '';
	var mi = '';
	var ss = '';

	if (d.getHours() < 10)
		hh = "0" + d.getHours();
	else
		hh = d.getHours();

	if (d.getMinutes() < 10)
		mi = "0" + d.getMinutes();
	else
		mi = d.getMinutes();

	if (d.getSeconds() < 10)
		ss = "0" + d.getSeconds();
	else
		ss = d.getSeconds();

	return hh + ":" + mi + ":" + ss;
}

function getLastUpdatedDate() {

	var d = new Date(document.lastModified);
	var dd = '';
	var mm = '';
	var yyyy = '';

	if (d.getDate() < 10)
		dd = "0" + d.getDate();
	else
		dd = d.getDate();

	if (d.getMonth() < 9)
		mm = "0" + (d.getMonth() + 1);
	else
		mm = d.getMonth() + 1;

	if (d.getYear() < 2000)
		yy = 1900 + d.getYear();
	else
		yy = d.getYear();

	return dd + "." + mm + "." + yy;

}

function getLastUpdated (p_index, p_target) {

	return	'<p><font size=-1>This page was last updated '
	+	getLastUpdatedDate()
	+	'.</font><p>'
	+	(
			p_index >= 0 ?
				PageFooterLinks (
					PageFooterLink (
						'Index'
					,	getPath(p_index) + 'index.htm'
					,	p_target
					)
				)
			:	''
		)
	;
}

function printLastUpdated (p_index, p_target) {
	p(getLastUpdated(p_index, p_target));
}

function showYear (p_year, p_finish) {

	if (p_finish == null) {
		p ('</dl>');
	}

	p (
		'<a name="'
	+	p_year
	+	'"><h2>'
	+	p_year
	+	'</h2></a><dl>'
	);
}


// email


function fixQuotes (s) {

	var s2 = s;
	var s3 = '';

	pos = s2.indexOf('"');

	if (pos > 0) {

		while (pos > 0) {

			s3 = s3 + s2.substring(0, pos) + '&quot;';

			s2 = s2.substring(pos + 1);

			pos = s2.indexOf('"');

		}

		s3 = s3 + s2;

	} else {

		s3 = s2;

	}

	return s3;

}

function fixSpaces (s) {

	var s2 = s;
	var s3 = '';

	pos = s2.indexOf(' ');

	if (pos > 0) {

		while (pos > 0) {

			s3 = s3 + s2.substring(0, pos) + '+';

			s2 = s2.substring(pos + 1);

			pos = s2.indexOf(' ');

		}

		s3 = s3 + s2;

	} else {

		s3 = s2;

	}

	return s3;

}

function fixSpaces2 (s) {

	var s2 = s;
	var s3 = '';

	var pos = s2.indexOf('+');

	if (pos > 0) {

		while (pos > 0) {

			s3 = s3 + s2.substring(0, pos) + ' ';

			s2 = s2.substring(pos + 1);

			pos = s2.indexOf('+');

		}

		s3 = s3 + s2;

	} else {

		s3 = s2;

	}

	return s3;

}

function fixSpaces3 (s) {

	var s2 = s;
	var s3 = '';

	pos = s2.indexOf(' ');

	if (pos > 0) {

		while (pos > 0) {

			s3 = s3 + s2.substring(0, pos) + '&nbsp;';

			s2 = s2.substring(pos + 1);

			pos = s2.indexOf(' ');

		}

		s3 = s3 + s2;

	} else {

		s3 = s2;

	}

	return s3;

}


// poems


function poems_index (p_this_poem, p_level) {

	if ((top != self) && (window.name == 'poem')) {
		window.parent.parent.menu.location = getPath(p_level) + 'menu.htm?p_poem=' + p_this_poem;
	}
}


// timeline


function showTC (p_picture, p_year) {

	if (p_picture != null && p_year != null) {

		window.open (
			'gallery/show_picture.htm'
		+	'?p_picture='
		+	p_picture
		+	'&p_year='
		+	p_year
		,	'_blank'
		,	'menu=1,status=0,toolbar=0,scrollbars=0,resizable=1,'
		+	'width=250,height=300,'
		+	'screenX=20,screenY=20,left=20,top=20'
		);

	} else {

		p (
			img (
				getURLparam('p_picture') + 'a.jpg'
			,	168
			,	230
			,	0
			,	'TC anno ' + getURLparam('p_year')
			)
		);

	}
}

function Is() {

	var agt = navigator.userAgent.toLowerCase();

	this.major = parseInt(navigator.appVersion);
	this.minor = parseFloat(navigator.appVersion);

	this.nav =
		((agt.indexOf('mozilla') != -1) && (agt.indexOf('spoofer') == -1)
	&&	(agt.indexOf('compatible') == -1) && (agt.indexOf('opera') == -1)
	&&	(agt.indexOf('webtv') == -1))
	;

	this.nav2 = (this.nav && (this.major == 2));
	this.nav3 = (this.nav && (this.major == 3));
	this.nav4 = (this.nav && (this.major == 4));
	this.nav4up = (this.nav && (this.major >= 4));
	this.navonly = (
		this.nav
	&&	((agt.indexOf(";nav") != -1)
	||	(agt.indexOf("; nav") != -1))
	);

	this.nav5 = (this.nav && (this.major == 5));
	this.nav5up = (this.nav && (this.major >= 5));

	this.ie = (agt.indexOf("msie") != -1);
	this.ie3 = (this.ie && (this.major < 4));
	this.ie4 = (this.ie && (this.major == 4) && (agt.indexOf("msie 5.0") == -1));
	this.ie4up = (this.ie  && (this.major >= 4));
	this.ie5 = (this.ie && (this.major == 4) && (agt.indexOf("msie 5.0") != -1));
	this.ie5up = (this.ie && !this.ie3 && !this.ie4);

	this.opera = (agt.indexOf("opera") != -1);
}

var is = new Is();


// lists


function LI (p_text) {
	return '<li>' + (p_text == null ? '' : p_text);
}

function PLI (p_text) {
	return '<p>' + LI(p_text);
}

function UL (p_items, p_attr) {
	return '<ul' + (p_attr == null ? '' : ' ' + p_attr) + '>' + p_items + '</ul>';
}

function OL (p_items, p_attr) {
	return '<ol' + (p_attr == null ? '' : ' ' + p_attr) + '>' + p_items + '</ol>';
}

function writeUL (p_items, p_attr) {
	p(UL(p_items, p_attr));
}

function writeOL (p_items, p_attr) {
	p(OL(p_items, p_attr));
}

var LICN = LI('Click Next');
var LICIA = LI('Click I Agree');
var LICI = LI('Click Install');
var LICF = LI('Click Finish');
var LICO = LI('Click OK');


// links


function setStatus (p_status) {
	window.status = p_status;
	return true;
}

function isInFrame() {
	return !(self == top);
}

function isOnServer() {
	return (location.href.indexOf('http://') > -1);
}

function getServerHomeURL() {
	return 'http://home.c2i.net/toreingolf/';
}

function getHomeURL() {
	return (isOnServer() ? getServerHomeURL() : 'file://C|/toreingolf/');
}

function getFormsURL() {
	return 'http://www.geocities.com/toreingolf/forms/';
}

function getPhotoURL (p_photo_id) {
	return 'http://www.flickr.com/photos/toreingolf/' + p_photo_id + '/';
}

function getPhotoLink (p_text, p_photo_id) {
	return EL(p_text, getPhotoURL(p_photo_id));
}

function getBottomLink (p_text, p_url, p_target) {

	return	(p_url == null ? p_text : '<a href="' + p_url + '"'
	+	(p_target == null ? '' : ' target="' + p_target + '"')
	+	' class="nu">' + p_text + '</a>')
	;
}

function getBottomLinks (p_links) {
	return	'<p><h5>[ ' + p_links + ' ]</h5>';
}

function writeBottomLinks (p_links) {
	p(getBottomLinks(p_links));
}

function getHomeLink (p_text, p_extra) {

	return	getBottomLinks (
			getBottomLink (
				(p_text == null ? 'Home' : p_text)
			,	(isOnServer() ? getHomeURL() : '../index.htm')
			,	'_top'
			)
		+	(p_extra == null ? '' : p_extra)
		)
	;
}

function writeHomeLink (p_text, p_extra) {
	p(getHomeLink(p_text, p_extra));
}

function PopUp (p_url, p_width, p_height, p_status, p_xpos, p_ypos) {

	window.open (
		p_url
	,	'_blank', 'status=' + (p_status == null ? 0 : p_status)
	+	',toolbar=0,scrollbars=1,resizable=1,width='
	+	(p_width == null ? 750 : p_width)
	+	',height='
	+	(p_height == null ? 550 : p_height)
	+	',screenX='
	+	(p_xpos == null ? 30 : p_xpos)
	+	',screenY='
	+	(p_ypos == null ? 30 : p_ypos)
	+	',left='
	+	(p_xpos == null ? 30 : p_xpos)
	+	',top='
	+	(p_ypos == null ? 30 : p_ypos)
	);
}

function aaaPopUp (p_term) {
	PopUp('http://www.acronymfinder.com/af-query.asp?String=exact&Acronym=' + p_term, 700, 500, 0, 30, 30);
}

function getAAALink (p_term) {
	return 'JavaScript:aaaPopUp(\'' + p_term + '\');';
}

function rfcURL (p_id) {
	return 'tools.ietf.org/html/rfc' + p_id
}

function getRefLink (p_filename, p_mode) {

	var l_offset = (location.href.indexOf('/how/') > -1 ? 20 : 0);
	var l_xpos = 30 + l_offset;
	var l_ypos = 30 + l_offset;

	return	' <a href="JavaScript:PopUp(\''
	+	getHomeURL()
	+	p_mode.toLowerCase() + '/'
	+	p_filename
	+	(p_filename.indexOf('.htm') > -1 ? '' : '.htm')
	+	'\',750,500,1,'
	+	l_xpos
	+	','
	+	l_ypos
	+	');" style="cursor:help" class="RefLink">'
	+	p_mode
	+	'?</a>'
	;
}

function HL (p_filename) {
	return getRefLink(p_filename, 'How');
}

function writeHL (p_filename, p_extra) {
	p(HL(p_filename) + (p_extra == null ? '' : p_extra));
}

function WL (p_filename) {
	return getRefLink(p_filename, 'Why');
}

function writeWL (p_filename, p_extra) {
	p(WL(p_filename) + (p_extra == null ? '' : p_extra));
}

function getCheatLink (p_filename) {

	return	'<a href="JavaScript:PopUp(\''
	+	getHomeURL()
	+	'how/cheat/'
	+	p_filename
	+	(p_filename.indexOf('.') > 0 ? '' : '.txt')
	+	'\',750,500,1);">'
	+	getIcon('list.gif', 13, 13, 0, 'Cheat Sheet')
	+	'</a>'
	;
}

function CheatLink (p_filename) {
	p(getCheatLink(p_filename));
}

function close_button() {

	p (
		'<form name="closebutton" action="" method="POST">'
	+	'<input type="submit" name="action" value="Close" onClick="window.close();">'
	+	'</form>'
	);

	document.closebutton.action.focus();
}

function HowHeader (p_title) {

	p (
		getTableOpenR()
	+	getTableCellVT (
			'<font class="h3">'
		+	(p_title == null ? document.title : p_title)
		+	'</font></td><td align=right valign=top>'
		+	'<form name="closebutton" action="" method="POST">'
		+	'<input type="submit" name="action" value="Close" onClick="window.close();">'
		)
	+	getTableCloseR()
	+	'</form>'
	);

	document.closebutton.action.focus();
}

function notrailingslash (p_url) {
	if (p_url.substr(p_url.length - 1, 1) == '/') {
		return p_url.substr(0, p_url.length - 1);
	} else {
		return p_url;
	}
}

function EL (p_text, p_url, p_extra, p_attr) {

	return	(p_url == null ? p_text : '<a href="'
	+	(p_url.indexOf('://') > 0 ? p_url : 'http://' + p_url)
	+	'" target="_blank"'
	+	(p_attr == null ? '' : ' ' + p_attr)
	+	'>'
	+	(p_text == null || p_text == '' ? notrailingslash(p_url) : p_text)
	+	'</a>')
	+	(p_extra == null ? '' : p_extra)
	;
}

function LEL (p_text, p_url, p_extra) {
	return LI(EL(p_text, p_url, p_extra));
}

function PLEL (p_text, p_url, p_extra) {
	return PLI(EL(p_text, p_url, p_extra));
}

function ELCOM (p_text, p_url, p_extra) {
	return EL(p_text, 'www.' + p_url + '.com/', p_extra);
}

function LELCOM (p_text, p_url, p_extra) {
	return LI(ELCOM(p_text, p_url, p_extra));
}

function ELORG (p_text, p_url, p_extra) {
	return EL(p_text, 'www.' + p_url + '.org/', p_extra);
}

function LELORG (p_text, p_url, p_extra) {
	return LI(ELORG(p_text, p_url, p_extra));
}

function ELGOV (p_text, p_url, p_extra) {
	return EL(p_text, 'www.' + p_url + '.gov/', p_extra);
}

function LELGOV (p_text, p_url, p_extra) {
	return LI(ELGOV(p_text, p_url, p_extra));
}

function ELNO (p_text, p_url, p_extra) {
	return EL(p_text, 'www.' + p_url + '.no/', p_extra);
}

function LELNO (p_text, p_url, p_extra) {
	return LI(ELNO(p_text, p_url, p_extra)); // getIcon('noflag.gif', 22, 16, 0, '', 'align=absbottom')
}

function IL (p_text, p_url, p_extra, p_target) {

	return	(p_url == null ? p_text : '<a href="'
	+	p_url
	+	'"'
	+	(p_target == null ? '' : ' target="' + p_target + '"')
	+	'>'
	+	(p_text == null ? p_url : p_text)
	+	'</a>')
	+	(p_extra == null ? '' : p_extra)
	;
}

function LIL (p_text, p_url, p_extra, p_target) {
	return LI(IL (p_text, p_url, p_extra, p_target));
}

function PLIL (p_text, p_url, p_extra, p_target) {
	return PLI(IL (p_text, p_url, p_extra, p_target));
}

function ILRSS (p_text, p_url, p_extra) {
	return IL(p_text, /* 'feed:' + */ p_url, p_extra);
}

function ILT (p_date, p_extra) {

	var l_year = p_date;
	var l_date = '';

	if (p_date.length > 4) {
		l_date = p_date.substr(0, 6);
		l_year = p_date.substr(6, 4);
	}

	return l_date + IL(l_year, getHomeURL() + 'about/timeline/index.htm#' + l_year, p_extra);
}

function ML (p_email) {
	return '<a href="mailto:' + p_email + '">' + p_email + '</a>';
}

function getTopicLink (p_text, p_topic, p_extra) {

	return	'<a href="http://www.answers.com/topic/'
	+	(p_topic == null ? p_text : p_topic)
	+	'" target="_blank" style="cursor:help" title="Definition of &quot;'
	+	(p_topic == null ? p_text : p_topic)
	+	'&quot;">'
	+	p_text
	+	'</a>'	
	+	(p_extra == null ? '' : p_extra)
	;
}

function getMailtoLink (p_email, p_name, p_prefix, p_suffix) {

	if (p_email == null) {
		return (p_name == null ? '' : p_name);
	} else {

		var isEmail = (p_email.substring(0, 7) != 'http://');

		return	(p_prefix == null ? '' : p_prefix)
		+	'<a href="'
		+	(isEmail ? 'mailto:' : '')
		+	p_email
		+	'"'
		+	(isEmail ? '' : ' target="_blank"')
		+	'>'
		+	(p_name == null ? p_email : p_name)
		+	'</a>'
		+	(p_suffix == null ? '' : p_suffix)
		;
	}
}

function getEmailTCLink (p_prompt, p_level, p_colon) {

	var l_path = getHomeURL();

	return	IL(p_prompt, 'mailto:toreingolf@yahoo.com' /* l_path + 'mail2tc.htm' */)
	+	(p_colon == null ? ':&nbsp;' : p_colon)
	+	IL (
			'<img src="'
		+	l_path
		+	'img/email.gif" width=17 height=12 border=0 alt="Send Message to TC">'
		,	'mailto:toreingolf@yahoo.com' /* l_path + 'mail2tc.htm' */
		)
	;
}

function writeEmailTCLink (p_prompt, p_level, p_colon) {
	p(getEmailTCLink(p_prompt, p_level, p_colon));
}

function getEmailHome() {
	return 'toreingolf@yahoo.com';
}

function getEmailWork() {
	return 'tore.christoffersen@nsa.no';
}

function ContactInfoField (p_prompt, p_value) {
	return getTableRow (
		getLayoutTableCell(p_prompt + '&nbsp;:&nbsp;', 'align=right')
	+	getLayoutTableCell(p_value)
	);
}

function writeContactInfo() {

	p (
		getTableOpen()
	+	ContactInfoField (
			EL('Name', 'www.ssb.no/navn/')
		,	EL('Tore Ingolf Christoffersen', 'www.ssb.no/vis/navn/sok.cgi?fornavn=Tore+Ingolf&etternavn=Christoffersen&base=mann')
		)
/*
	+	ContactInfoField (
			'Title'
		,	'Consultant, '
		+	getEvitaLink()
		)
*/
	+	ContactInfoField (
			EL('Mobile Phone', 'www.telenor.no/privat/mobil/')
		,	'+47 900 14 059'
		)
	+	ContactInfoField (
			ELNO('Mail', 'posten')
		,	EL (
				'Slal&aring;mveien 5E, 1410 Kolbotn, Norway'
			,	'http://www.finn.no/finn/mappopup?utmx=263920&utmy=6637127&mapTitle=SLAL%C5MVEIEN+5E&airPossible=1'
			)
		)
	+	ContactInfoField (
			EL('Email', 'mail.yahoo.com')
		,	ML(getEmailHome())
/*
		+	' (home)'
		+	' / '
		+	ML(getEmailWork())
		+	' (work)'
*/
		)
//	+	ContactInfoField('Email Subject Codes', 'I=Info U=Urgent A=Action required R=Reply required')
	+	ContactInfoField (
			ELCOM('Web', 'google')
		,	IL(null, getServerHomeURL(), null, '_top')
		+	' '
		+	ILRSS (
				getIconRSS()
			,	getServerHomeURL() + 'rss/updates.xml'
			)
		)
	+	ContactInfoField (
			ELCOM('LinkedIn', 'linkedin')
		,	EL (
				'' // getIcon('linkedin_profile.gif', 80, 15, 0, 'LinkedIn Profile')
			,	'http://www.linkedin.com/in/toreingolf'
			)
		)
	+	ContactInfoField (
			ELCOM('Plaxo', 'plaxo')
		,	EL (
				''
			,	'http://toreingolf.myplaxo.com'
			)
		)
	+	ContactInfoField (
			ELCOM('Facebook', 'facebook')
		,	EL (
				'' // getIcon('find_us_on_facebook_badge.gif', 80, 24, 0)
			,	'http://www.facebook.com/toreingolf' // www.facebook.com/profile.php?id=837903636
			)
		)
	+	ContactInfoField (
			ELNO('iam', 'iam')
		,	EL (
				''
			,	'http://www.iam.no/privat/eX1mipts' // http://www.iam.no/privat/442255
			)
		)
	+	ContactInfoField (
			ELNO('folk.no', 'folk')
		,	EL (
				''
			,	'http://folk.no/90014059'
			)
		)
	+	ContactInfoField (
			ELNO('Gule Sider', 'gulesider')
		,	EL (
				''
			,	'http://www.gulesider.no/telefonkatalogen/Tore_Ingolf_Christoffersen/0000324905800000000/'
			)
		)
	+	ContactInfoField (
			ELCOM('Flickr', 'flickr')
		,	EL (
				''
			,	'http://www.flickr.com/photos/toreingolf'
			)
		)
	+	ContactInfoField (
			ELCOM('Twitter', 'twitter')
		,	EL (
				'' // getIcon('twitter_logo_header.png', 80, 19, 0) // 155x36
			,	'http://twitter.com/toreingolf'
			)
		)
	+	ContactInfoField (
			EL('Oracle Blog', 'blogs.oracle.com')
		,	EL (
				'' // getIcon('otn_blogs.gif', 80, 15, 0)
			,	'http://toreingolf.blogspot.com/'
			)
		)
	+	ContactInfoField (
			EL('Oracle Mix', 'mix.oracle.com')
		,	EL (
				'' // getIcon('otn_blogs.gif', 80, 15, 0)
			,	'https://mix.oracle.com/user_profiles/93247-tore-ingolf-christoffersen'
			)
		)
	+	getTableClose()
	);
}

function getMoreLink (p_text, p_url, p_source) {

	return	EL(p_text, p_url)
	+	(p_source == null ? '' : (p_source == '' ? '' : '<font size=-1> ' + p_source + '</font>'))
	;
}

function getSprakradURL() {
	return 'http://www.sprakrad.no/';
}

function getSprakradBaseLink() {
	return EL('Spr&aring;kr&aring;det', getSprakradURL());
}

function getSprakradLink (p_text, p_article, p_source) {

	return	getMoreLink (
			p_text
		,	getSprakradURL()
		+	(p_article == null ? '' : 'templates/Page.aspx?id=' + p_article)
		,	(p_source == null ? ' (' + getSprakradBaseLink() + ')' : p_source)
		)
	;
}

function getSprakradLink2 (p_text, p_url, p_source) {

	return	getMoreLink (
			p_text
		,	getSprakradURL()
		+	(p_url == null ? '' : p_url)
		,	(p_source == null ? ' (' + getSprakradBaseLink() + ')' : p_source)
		)
	;
}

function getAftenpostenURL() {
	return 'http://www.aftenposten.no/';
}

function getAftenpostenBaseLink() {
	return EL('Aftenposten', getAftenpostenURL());
}

function getAftenpostenLink (p_text, p_section, p_article, p_author, p_email, p_date) {

	return	getMoreLink (
			p_text
		,	getAftenpostenURL() + p_section
		+	(p_article == null ? '' : '/article' + p_article + '.ece')
		,	(p_author == null ? '' : ' av ' + getMailtoLink(p_email, p_author))
		+	(p_date == null ? '' : ' (' + p_date + ')')
		)
	;
}

function getAftenpostenImgLink (p_text, p_section, p_article, p_imgno, p_source) {

	return	getMoreLink (
			p_text
		,	getAftenpostenURL() + p_section
		+	(p_article == null ? '' : '/article' + p_article + '.ece')
		+	'?service=bildeviser&nr='
		+	(p_imgno == null ? '0' : p_imgno)
		+	'&felt=brodtekst'
		,	p_source
		)
	;
}

function getWikipediaBaseURL() {
	return 'http://www.wikipedia.org/';
}

function getWikipediaBaseLink() {
	return EL('Wikipedia', getWikipediaBaseURL());
}

function getWikipediaURL (p_language, p_subject) {
	return 'http://' + p_language + '.wikipedia.org/wiki/' + p_subject;
}

function getWikipediaLink (p_text, p_language, p_subject, p_source) {

	return	getMoreLink (
			p_text
		,	getWikipediaURL(p_language, p_subject)
		,	(p_source == null ? ' (' + getWikipediaBaseLink() + ')' : p_source)
		)
	;
}

function getAFURL() {
	return 'http://www.adopsjonsforum.no/';
}

function getAFBaseLink() {
	return EL('Adopsjonsforum', 'http://www.adopsjonsforum.no/');
}

function getAFLink (p_text, p_article, p_date) {

	return	getMoreLink (
			p_text
		,	'http://www.adopsjonsforum.no/'
		+	(p_article == null ? '' : 'index.aspx?article=' + p_article)
		,	' ('
		+	getAFBaseLink()
		+	' '
		+	p_date
		+	')'
		)
	;
}

function getBBSURL() {
	return 'http://www.bbs-nordic.com/no/';
}

function getBBSLink (p_text) {
	return EL((p_text == null ? 'BBS' : p_text), getBBSURL());
}

function getEvitaURL() {
	return 'http://www.e-vita.no/ikbViewer/page/no/evita/hovedside'; // http://www.evita.no/portal/page/portal/evita.no/hovedside
}

function getEvitaLink (p_text, p_extra) {
	return EL((p_text == null ? 'e-vita' : p_text), getEvitaURL(), p_extra);
}

function getNSAURL() {
	return 'http://www.nsa.no/';
}

function getNSALink (p_text, p_extra) {
	return EL((p_text == null ? 'NSA' : p_text), getNSAURL(), p_extra);
}

function getAMOLink() {
	return EL('Astronomer mot orddeling', 'http://www.amo.no/');
}

function getKHL (p_text, p1, p2, p_extra) {

	return	EL (
			p_text
		,	'http://www.kongehuset.no/'
		+	p1
		+	'/seksjonstekst_person/vis.html?tid='
		+	p2
		,	p_extra
		)
	;
}

function getKongehusetLink (p_text, p_initials, p_extra) {

	if (p_initials == 'O')       return getKHL(p_text, 'c26968', '27768');
	else if (p_initials == 'H')  return getKHL(p_text, 'c26952', '27205');
	else if (p_initials == 'S')  return getKHL(p_text, 'c26953', '27197');
	else if (p_initials == 'HM') return getKHL(p_text, 'c27226', '27658');
	else if (p_initials == 'MM') return getKHL(p_text, 'c27227', '27661');
	else if (p_initials == 'IA') return getKHL(p_text, 'c27228', '27662');
	else return p_text;
}

function getLatitudeLink (p_extra) {
	return EL('Latitude', 'www.dell.com/content/products/compare.aspx/latit?c=us&cs=555&l=en&s=biz', p_extra);
}

function getEditorLinks() {
	return	UL (
			LELCOM('TextPad', 'textpad')
		+	LELCOM('EditPad Pro', 'editpadpro')
		+	LELCOM('UltraEdit', 'ultraedit')
		+	LEL('NotePad+', 'www.mypeecee.org/rogsoft/notepad.html')
		+	LEL('NotePad++', 'notepad-plus.sourceforge.net/')
		)
	;
}

function getJSRURL (p_jsr) {
	return 'www.jcp.org/en/jsr/detail?id=' + p_jsr;
}

function getJSRLink (p_jsr, p_text, p_extra) {
	return EL((p_text == null ? 'JSR-' + p_jsr : p_text), getJSRURL(p_jsr), p_extra);
}

function getTimeBaseURL() {
	return 'http://www.timeanddate.com';
}

function getTimeURL (p_code) {

	var l_area = '';

	if (
		(p_code == 'PDT')
	||	(p_code == 'PST')
	||	(p_code == 'MDT')
	||	(p_code == 'MST')
	||	(p_code == 'CDT')
	||	(p_code == 'CST')
	||	(p_code == 'EDT')
	||	(p_code == 'EST')
	) {
		l_area = 'na';
	} else if (
		(p_code == 'BST')
	||	(p_code == 'CET')
	||	(p_code == 'CEST')
	||	(p_code == 'GMT')
	||	(p_code == 'UTC')
	) {
		l_area = 'eu';
	}

	return getTimeBaseURL()
	+	'/library/abbreviations/timezones/'
	+	l_area
	+	'/'
	+	(p_code == 'UTC' ? 'gmt' : p_code.toLowerCase())
	+	'.html'
	;
}

function getTimeLink (p_code, p_text) {
	return EL((p_text == null ? p_code : p_text), getTimeURL(p_code));
}

function getTimeCityLink (p_id, p_name) {
	return EL(p_name, getTimeBaseURL() + '/worldclock/city.html?n=' + p_id);
}

function getTimeContinentLink (p_id, p_name) {
	return EL(p_name, getTimeBaseURL() + '/worldclock/' + (p_id == null ? '' : 'custom.html?continent=' + p_id));
}

function getFormLink (p_form_name) {
	return getHomeURL() + 'forms/loadform.htm?p_form_name=' + p_form_name;
}


// soapbox


function getAuthor (p_author) {

	var l_author = '';

	if (p_author == "CE") {
		l_author = '<a href="mailto:comments@catoeik.com" target="_blank">Cato&nbsp;Eik</a>';
	} else if (p_author == "TC") {
		l_author = '<a href="mailto:toreingolf@yahoo.com">TC</a>';
	} else if (p_author == "FH") {
		l_author = '<a href="mailto:fredrik.holst@oracle.com" target="_blank">Fredrik&nbsp;Holst</a>';
	} else if (p_author == "OD") {
		l_author = '<a href="mailto:ornulf.dahl@oracle.com" target="_blank">Langbein</a>';
	}

	return l_author;
}


// menus


function MI_DD_mouse (p_sm_id) {
	return (p_sm_id > 0 ? ' onmouseover="MI_DD_show(' + p_sm_id + ')" onmouseout="MI_DD_hide()"' : '');
}

function MI_get (p_prompt, p_url, p_hi, p_div, p_sm_id) {

	if ((p_hi == '!') || (location.href.indexOf((p_hi == null || p_hi == '' ? p_url : p_hi)) > 0)) {

		l_class = ' class="hi"';

	} else {

		l_class = '';

	}

	return	'<li'
	+	'><nobr><a'
	+	l_class
	+	' href="'
	+	(p_url.indexOf('://') > 0 ? '' : getHomeURL())
	+	p_url
	+	'"'
	+	' target="_top"'
	+	MI_DD_mouse(p_sm_id)
	+	'>'
	+	fixSpaces3(p_prompt)
	+	'</a>'
	+	(p_div == null ? ' | ' : p_div)
	+	'</nobr>'
	;
}

function MI (p_prompt, p_url, p_hi, p_div, p_sm_id) {
	p(MI_get(p_prompt, p_url, p_hi, p_div, p_sm_id));
}

function MI_L1 (p_prompt, p_url, p_hi, p_sm_id) {
	MI(p_prompt, p_url, p_hi, '', p_sm_id);
}

function MI_L2 (p_prompt, p_url, p_hi, p_sm_id) {
	MI(p_prompt, p_url, p_hi);
}

function MI_L2_get (p_prompt, p_url, p_hi, p_sm_id, p_sm_id2) {
	MI_DD(p_prompt, p_url);
	if (p_sm_id == p_sm_id2) {
		return MI_get(p_prompt, p_url, p_hi);
	} else {
		return '';
	}
}

function MI_open() {
	p(getTableOpenR() + '<td>');
}

function MI_close() {
	p('</td>' + getTableCloseR());
}

function MI_L1_open() {

	roImageNew(getHomeURL() + 'v22g01',  20, 20, 'gif');

	p (
		getTableOpen(0, 0, 5)
	+	'<tr bgcolor="#666666">'
	+	getTableCell (
			getIcon('blankdot.gif', 5, 1)
		+	getroImage('v22g01', 20, 20, 'gif', 'Home', 'index.htm')
		,	'width=25'
		)
	+	'<td><ul class="tb1" id="ddm">'
	);
}

function MI_L1_close (p_button) {
	p (
		'</ul></td><td valign=top align=right>'
	+	(p_button == null ? '&nbsp;' : p_button)
	+	'</td></tr></table>'
	);
}

function MI_L2_open() {
	p (
		getTableOpen()
	+	'<tr><td><ul class="tb2"><li>|</li>'
	);
}

function MI_L2_close() {
	p (
		'</ul></td></tr></table>'
	);
}

function MI_DD_open (p_id) {
	p (
		'<div class="ddm" id="' + p_id + '"' + MI_DD_mouse(p_id) + '>'
	);
}

function MI_DD_close() {
	p (
		'</div></li>'
	);
}

function MI_DD (p_prompt, p_url) {
	p (
		'<nobr><a href="'
	+	(p_url.indexOf('://') > 0 ? '' : getHomeURL())
	+	p_url
	+	'">'
	+	p_prompt
	+	'</a></nobr>'
	);
}

var ddm_mi = 0;

function MI_DD_show(p_id) {

	if (ddm_mi) ddm_mi.style.visibility = 'hidden';

	ddm_mi = document.getElementById(p_id);
	ddm_mi.style.visibility = 'visible';
//	ddm_mi.moveBy(-100,0);

}

function MI_DD_hide() {
	if (ddm_mi) ddm_mi.style.visibility = 'hidden';
}

function MI_P (p_prompt, p_url, p_div, p_target) {
	return	'<a href="'
	+	(p_url == null ? p_prompt : p_url)
	+	'"'
	+	(p_target == null ? '' : ' target="' + p_target + '"')
	+	'>'
	+	p_prompt
	+	'</a>'
	+	(p_div == null ? ' | ' : p_div)
	;
}

function getYearLink (p_year, p_div) {
	return MI_P(p_year, '#' + p_year, p_div);
}

function PL (p_prompt, p_anchor, p_div) {
	return MI_P(p_prompt, '#' + (p_anchor == null ? p_prompt : p_anchor), p_div);
}

function PL_intro() {
	return PL('Introduction', 'intro');
}

function PL_before_you_begin() {
	return PL('Before you begin', 'before_you_begin');
}

function PL_whatsnext() {
	return PL('What\'s Next?', 'next');
}

function PL_resources() {
	return PL('Resources', 'resources');
}

function PL_getting_started() {
	return PL('Getting started', 'getting_started');
}

function PL_start_and_stop() {
	return PL('Startup and Shutdown', 'start_and_stop');
}

function PL_develop() {
	return PL('Developing', 'develop');
}

function PL_deploy() {
	return PL('Deploying', 'deploy');
}

function PL_test() {
	return PL('Testing', 'test');
}

function PL_redeploy() {
	return PL('Redeploying', 'redeploy');
}

function PL_invoke() {
	return PL('Invoking', 'invoke');
}

function PL_inst() {
	return PL('Installing', 'inst');
}

function PL_preinst() {
	return PL('Pre-installation Tasks', 'preinst');
}

function PL_postinst() {
	return PL('Post-installation Tasks', 'postinst');
}

function PL_mini_app() {
	return PL('A Mini Application', 'mini_app');
}

function PL_moreinfo() {
	return PL('More Information', 'moreinfo');
}

function getSection (p_name, p_title, p_href, p_target) {

	return	'<a name="'
	+	p_name
	+	'"'
	+	(p_href == null ? '' : ' href="' + p_href + '"')
	+	(p_target == null ? '' : ' target="' + p_target + '"')
	+	'><h3>'
	+	(p_title == null ? p_name : p_title)
	+	'</h3></a>'
	;
}

function writeSection (p_name, p_title, p_href, p_target) {
	p(getSection(p_name, p_title, p_href, p_target));
}

function getSectionMoreInfo() {
	return getSection('moreinfo', 'More Information');
}

function writeSectionIntro() {
	writeSection('intro', 'Introduction');
}

function writeSectionDisclaimer() {
	writeSection('disclaimer', 'Disclaimer');
}

function writeSectionInst() {
	writeSection('inst', 'Installing');
}

function writeSectionPreInst() {
	writeSection('preinst', 'Pre-installation Tasks');
}

function writeSectionPostInst() {
	writeSection('postinst', 'Post-installation Tasks');
}

function writeSectionStartStop() {
	writeSection('start_and_stop', 'Startup and Shutdown');
}

function writeSectionWhatsNext() {
	writeSection('next', 'What\'s Next?');
}

function writeSectionMoreInfo() {
	p(getSectionMoreInfo());
}

function writeSectionLinks() {
	writeSection('links', 'Links');
}

function writeSectionSetup() {
	writeSection('setup', 'Setup');
}

function showPageLinks (p_links) {
	p (
		'<font class="menu_light">[ '
	+	p_links.substr(0, p_links.length - 2)
	+	' ]</font>'
	);
}

function getBabelfishLink (p_path, p_lang) {
	return 'http://babelfish.yahoo.com/translate_url?trurl=http%3A%2F%2Fhome.c2i.net%2Ftoreingolf%2F'
	+	p_path
	+	'&lp='
	+	p_lang
	+	'&tt=url'
	;
}

function showMenu (p_button, p_option, p_hi) {

	var l_opt = (p_option == null ? '' : p_option);
	var l_sm_id = 0;
	var l_sm = null;

	if (l_opt.substring(0, 5)  == 'about') {
		l_sm_id = 1;
	} else if (l_opt.substring(0, 6) == 'guides') {
		l_sm_id = 2;
	} else if (l_opt == 'jokes') {
		l_sm_id = 3;
	} else if (l_opt == 'links') {
		l_sm_id = 4;
	} else if (l_opt == 'oracle') {
		l_sm_id = 5;
	} else if (l_opt == 'poems') {
		l_sm_id = 6;
	} else if (l_opt == 'starters') {
		l_sm_id = 7;
	}

	p('<a name="top"></a>');

	MI_open();

	MI_L1_open();

	MI_L1('About TC', 'about/tc.htm', 'about', 1);

	MI_DD_open(1);
	l_sm =	MI_L2_get('Books', 'about/books.htm', '', 1, l_sm_id)
	+	MI_L2_get('Cameras', 'about/cameras/index.htm', '', 1, l_sm_id)
	+	MI_L2_get('Computers', 'about/computers/index.htm', '', 1, l_sm_id)
	+	MI_L2_get('CV', 'about/cv/en.htm', '', 1, l_sm_id)
	+	MI_L2_get('Employers', 'about/employers.htm', '', 1, l_sm_id)
	+	MI_L2_get('Hobbies', 'about/hobbies.htm', '', 1, l_sm_id)
	+	MI_L2_get('Life', 'about/life/index.htm', 'about/life', 1, l_sm_id)
	+	MI_L2_get('Music', 'about/music/index.htm', '', 1, l_sm_id)
	+	MI_L2_get('Pictures', 'about/timeline/pictures.htm', '', 1, l_sm_id)
	+	MI_L2_get('Time Line', 'about/timeline/index.htm', '', 1, l_sm_id)
	+	MI_L2_get('Vehicles', 'about/vehicles/index.htm', '', 1, l_sm_id)
	;
	MI_DD_close();

	MI_L1('Guides', 'guides/index.htm', 'guides/', 2);

	MI_DD_open(2);
	l_sm +=	MI_L2_get('Acronyms and Abbreviations', 'guides/aaa/index.htm', '', 2, l_sm_id)
	+	MI_L2_get('Chess', 'guides/chess/index.htm', '', 2, l_sm_id)
	+	MI_L2_get('Computers', 'guides/computers/index.htm', '', 2, l_sm_id)
	+	MI_L2_get('HTML', 'guides/languages/html/intro.htm', 'guides/languages/html', 2, l_sm_id)
	+	MI_L2_get('HTTP Status Codes', 'guides/http/status_codes.htm', 'guides/http', 2, l_sm_id)
	+	MI_L2_get('Java Applets', 'guides/languages/java/index.htm', '', 2, l_sm_id)
	+	MI_L2_get('Java vs PL/SQL', 'guides/languages/java_vs_plsql/index.htm', '', 2, l_sm_id)
	+	MI_L2_get('Norwegian Car Plates', 'guides/plates/no/index.htm', '', 2, l_sm_id)
	+	MI_L2_get('Norwegian Flag', 'guides/flags/no/index.htm', '', 2, l_sm_id)
	+	MI_L2_get('Norwegian Language', 'guides/languages/no/index.htm', '', 2, l_sm_id)
	+	MI_L2_get('Norwegian Litterature', 'texts/index.htm', '', 2, l_sm_id)
	+	MI_L2_get('Passwords', 'guides/passwords/index.htm', '', 2, l_sm_id)
	+	MI_L2_get('Time', 'guides/time/index.htm', '', 2, l_sm_id)
	+	MI_L2_get('UNIX', 'guides/unix/index.htm', '', 2, l_sm_id)
//	+	MI_L2_get('Windows', 'guides/windows/shortcut_keys.htm', '', 2, l_sm_id)
	+	MI_L2_get('XML', 'guides/languages/xml/intro.htm', 'guides/languages/xml', 2, l_sm_id)
	;
	MI_DD_close();

	// MI_L1('IBM', 'ibm/was61/install.htm', 'ibm');

	MI_L1('iKnowBase', 'ikb/index.htm', 'ikb');

	MI_L1('Jokes', 'jokes/index.htm', 'joke', 3);

	MI_DD_open(3);
	l_sm +=	MI_L2_get('English', 'jokes/index.htm', '', 3, l_sm_id)
	+	MI_L2_get('French', getBabelfishLink('jokes%2Findex.htm', 'en_fr'), '', 3, l_sm_id)
	+	MI_L2_get('German', getBabelfishLink('jokes%2Findex.htm', 'en_de'), '', 3, l_sm_id)
	+	MI_L2_get('Spanish', getBabelfishLink('jokes%2Findex.htm', 'en_es'), '', 3, l_sm_id)
	;
	MI_DD_close();

	MI_L1('Links', 'links/index.htm', 'link', 4);

	MI_DD_open(4);
	l_sm +=	MI_L2_get('Entertainment', 'links/ent.htm', '', 4, l_sm_id)
	+	MI_L2_get('Favorites', 'links/index.htm', '', 4, l_sm_id)
	+	MI_L2_get('Hardware &amp; Software', 'links/hwsw.htm', '', 4, l_sm_id)
	+	MI_L2_get('Homepages', 'links/homes.htm', '', 4, l_sm_id)
	+	MI_L2_get('Guides', 'links/gui.htm', '', 4, l_sm_id)
	+	MI_L2_get('Internet', 'links/int.htm', '', 4, l_sm_id)
	+	MI_L2_get('Miscellaneous', 'links/misc.htm', '', 4, l_sm_id)
	+	MI_L2_get('News / TV', 'links/news.htm', '', 4, l_sm_id)
//	+	MI_L2_get('Other Companies', 'links/oth.htm', '', 4, l_sm_id)
	+	MI_L2_get('Search', 'search/index.htm', '', 4, l_sm_id)
//	+	MI_L2_get('Add a Link', getFormLink('addlink'), '', 4, l_sm_id)
	;
	MI_DD_close();

	// MI_L1('Opinions', 'soapbox/index.htm', 'soapbox/');

	MI_L1('Oracle', 'oracle/index.htm', 'oracle', 5);

	MI_DD_open(5);
	l_sm +=	MI_L2_get('Disclaimer', 'oracle/disclaimer.htm', '', 5, l_sm_id)
	+	MI_L2_get('Installation Guides', 'oracle/installs.htm', (p_hi == 'inst' ? '!' : ''), 5, l_sm_id)
	+	MI_L2_get('Tutorials', 'oracle/tutorials.htm', (p_hi == 'tut' ? '!' : ''), 5, l_sm_id)
	+	MI_L2_get('References', 'oracle/references.htm', (p_hi == 'ref' ? '!' : ''), 5, l_sm_id)
	+	MI_L2_get('Archive', 'oracle/archive.htm', '', 5, l_sm_id)
	+	MI_L2_get('Online Documentation', 'oracle/doc.htm', '', 5, l_sm_id)
	+	MI_L2_get('Portal', 'oracle/index.htm#portal', '', 5, l_sm_id)
	+	MI_L2_get('Oracle Online', 'oracle/index.htm#online', '', 5, l_sm_id)
	+	MI_L2_get('Best Practice', 'oracle/index.htm#best_practice', '', 5, l_sm_id)
	+	MI_L2_get('Tools', 'oracle/index.htm#tools', '', 5, l_sm_id)
	+	MI_L2_get('Organizations &amp; Persons', 'oracle/index.htm#resources', '', 5, l_sm_id)
	;
	MI_DD_close();

	// MI_L1('PDA', 'palm/config.htm', 'palm');

	MI_L1('Photos', 'photos/index.htm', 'photo');

	MI_L1('Poems', 'poems/index.htm', 'poem', 6);

	MI_DD_open(6);
	l_sm +=	MI_L2_get('Index', 'poems/index.htm', '', 6, l_sm_id)
	+	MI_L2_get('0 - 100', 'poems/100.htm', '', 6, l_sm_id)
	+	MI_L2_get('101 - 200', 'poems/200.htm', '', 6, l_sm_id)
	+	MI_L2_get('201 - 300', 'poems/300.htm', '', 6, l_sm_id)
	+	MI_L2_get('301 - 400', 'poems/400.htm', '', 6, l_sm_id)
	+	MI_L2_get('401 - 500', 'poems/500.htm', '', 6, l_sm_id)
	;
	MI_DD_close();

	MI_L1('Starters', 'starters/index.htm', 'starters', 7);

	MI_DD_open(7);
	l_sm +=	MI_L2_get('APEX', 'starters/apex/index.htm', '', 7, l_sm_id)
	+	MI_L2_get('GlassFish', 'starters/glassfish/index.htm', '', 7, l_sm_id)
	+	MI_L2_get('Java', 'starters/java/index.htm', '', 7, l_sm_id)
	+	MI_L2_get('JMeter', 'starters/jmeter/index.htm', '', 7, l_sm_id)
	+	MI_L2_get('PHP', 'starters/php/index.htm', '', 7, l_sm_id)
	+	MI_L2_get('RMAN', 'starters/rman/index.htm', '', 7, l_sm_id)
	+	MI_L2_get('RSS', 'starters/rss/index.htm', '', 7, l_sm_id)
	+	MI_L2_get('Tomcat', 'starters/tomcat/index.htm', '', 7, l_sm_id)
	+	MI_L2_get('VirtualBox', 'starters/virtualbox/index.htm', '', 7, l_sm_id)
	+	MI_L2_get('VMware Player', 'starters/vmware/index.htm', '', 7, l_sm_id)
	+	MI_L2_get('WebLogic', 'starters/weblogic/index.htm', '', 7, l_sm_id)
	;
	MI_DD_close();

	// MI_L1('Subscribe', 'missing.htm?URL=subscr', 'subscr');

	// MI_L1('TCutilities', 'tcu/index.htm', 'tcu/');

	MI_L1('Tools', 'toolbox/index.htm', 'tool');

	MI_L1('Updates', 'whatsnew.htm', 'whatsnew');

	MI_L1_close(p_button);

	if (l_sm != '') {
		MI_L2_open();
		p(l_sm);
		MI_L2_close();
	}

	if (l_opt == 'about_life') {

		MI_L2_open();

		for (l_year = 1965; l_year < 2009; l_year++) {
			MI_L2(l_year.toString(), 'about/life/' + l_year.toString() + '.htm');
		}

		MI_L2_close();
	}

	if (l_opt == 'guides_html') {
		MI_L2_open();
		MI_L2('Introduction', 'guides/languages/html/intro.htm');
		MI_L2('Basics', 'guides/languages/html/basics.htm');
		MI_L2('Special Characters', 'guides/languages/html/charcode.htm');
		MI_L2('Headings', 'guides/languages/html/headings.htm');
		MI_L2('Fonts', 'guides/languages/html/fonts.htm');
		MI_L2('Character Formatting', 'guides/languages/html/format.htm');
		MI_L2('Horizontal Rulers', 'guides/languages/html/rulers.htm');
		MI_L2('Color Palette', 'guides/languages/html/colors.htm');
		MI_L2('Images', 'guides/languages/html/images.htm');
		MI_L2('Testing', 'guides/languages/html/testing.htm');
		MI_L2('Uploading HTML files', 'guides/languages/html/upload.htm');
		MI_L2('Tricks', 'guides/languages/html/tricks.htm');
		MI_L2('Search Engine Optimization', 'guides/languages/html/seo.htm');
		MI_L2_close();
	}

/*
	if (l_opt == 'guides_win') {
		MI_L2_open();
		MI_L2('Shortcut keys', 'guides/windows/shortcut_keys.htm');
		MI_L2('Files', 'guides/windows/files.htm');
		MI_L2('Search', 'guides/windows/search.htm');
		MI_L2('Selecting Text', 'guides/windows/selecting_text.htm');
		MI_L2_close();
	}
*/

	if (l_opt == 'guides_xml') {
		MI_L2_open();
		MI_L2('Introduction', 'guides/languages/xml/intro.htm');
		MI_L2('Basics', 'guides/languages/xml/basics.htm');
		MI_L2('My First XML', 'guides/languages/xml/xml.htm');
		MI_L2('DTD', 'guides/languages/xml/dtd.htm');
		MI_L2('XSD', 'guides/languages/xml/xsd.htm');
		MI_L2('XSL', 'guides/languages/xml/xsl.htm');
		MI_L2('XSD + XSL', 'guides/languages/xml/xsd_and_xsl.htm');
		MI_L2('Encoding', 'guides/languages/xml/encoding.htm');
		MI_L2('XML and Java', 'guides/languages/xml/java.htm');
		MI_L2('JDeveloper Tools', 'guides/languages/xml/jdev_ext_tools.htm');
		MI_L2('XML DB', 'guides/languages/xml/xmldb.htm');
		MI_L2_close();
	}

	if (l_opt == 'guides_computers') {
		MI_L2_open();
		MI_L2('Index', 'guides/computers/index.htm');
		MI_L2('Hardware', 'guides/computers/1_hw.htm');
		MI_L2('Software', 'guides/computers/2_sw.htm');
		MI_L2('Operating Systems', 'guides/computers/3_os.htm');
		MI_L2('Windows', 'guides/computers/4_win.htm');
		MI_L2('Managing Files', 'guides/computers/5_files.htm');
		MI_L2('Networks', 'guides/computers/6_net.htm');
		MI_L2('Internet and Web', 'guides/computers/7_int_web.htm')
		MI_L2_close();
	}

	MI_close();
}


// misc


function img (p_filename, p_width, p_height, p_hspace, p_alt, p_attr, p_text, p_url, p_target) {

	return	(p_text == null ? '' : getTableOpenR(0, 0, 0, p_width) + '<td>')
	+	(p_url == null ? '' : '<a href="' + p_url + '"' + (p_target == null ? '' : ' target="' + p_target + '"') + '>')
	+	'<img src="'
	+	p_filename
	+	'" border=0'
	+	(p_width == null ? '' : ' width=' + p_width)
	+	(p_height == null ? '' : ' height=' + p_height)
	+	' hspace='
	+	(p_hspace == null ? '0' : p_hspace)
	+	' vspace=0 alt="'
	+	(p_alt == null ? '' : p_alt)
	+	'" galleryimg=no'
	+	(p_attr == null ? '' : ' ' + p_attr)
	+	'>'
	+	(p_url == null ? '' : '</a>')
	+	(p_text == null ? '' : '</td></tr><tr><td class="textimg">' + (p_text == '=' ? p_alt : p_text) + '</td>' + getTableCloseR())
	;
}

function getIconPath() {
	return getHomeURL() + 'img/';
}

function getIcon (p_filename, p_width, p_height, p_hspace, p_alt, p_attr) {
	return img(getIconPath() + p_filename, p_width, p_height, p_hspace, p_alt, p_attr);
}

function getIconPointer (p_hspace) {
	return getIcon('item.gif', 6, 11, p_hspace, 'Click');
}

function getIconIndex (p_hspace) {
	return getIcon('itemix.gif', 11, 11, p_hspace, 'Index');
}

function getIconPrev (p_hspace) {
	return getIcon('itemprev.gif', 10, 11, p_hspace, 'Previous');
}

function getIconNext (p_hspace) {
	return getIcon('itemnext.gif', 10, 11, p_hspace, 'Next');
}

function getIconRSS (p_hspace) {
	return getIcon('feed-icon-14x14.png', 14, 14, p_hspace, 'RSS Feed');
}

function getPageOpen() {
	return '<div class="bodyframe">';
}

function getPageClose (p_what, p_updated, p_top_link) {

	if (getMedium() != 'printer') {

		return '<p>&nbsp;<p></div>'
		+	getTableOpenR()
		+	getTableCell (
				'<font size=1>This '
			+	(p_what == null ? 'page' : p_what)
			+	' was last updated '
			+	(p_updated == null ? getLastUpdatedDate() : p_updated)
			+	'.</font>'
			)
		+	getTableCell (
				'<font size=1>'
			+	(p_top_link == 0 ? '' : getMediumLink('printer') + ' | ' + IL('Back to top', '#'))
			+	'</font>'
			,	'align=right'
			)
		+	getTableCloseR()
		;

	} else {

		return '';

	}
}

function isNoTitle (p_title) {
	return ((p_title == null) || (p_title == ''));
}

function getPageTitle (p_title) {

	var l_title = (isNoTitle(p_title) ? document.title : p_title);

	if (location.href.indexOf('guides/languages/html') > 0) {
		l_title = 'HTML Guide : ' + l_title;
	} else if (location.href.indexOf('guides/languages/xml') > 0) {
		l_title = 'XML Guide : ' + l_title;
	} else if (location.href.indexOf('guides/windows') > 0) {
		l_title = 'Windows Guide : ' + l_title;
	} else if (location.href.indexOf('poems/poem') > 0) {
		l_title = 'Poem : ' + l_title;
	} else if (
		(location.href.indexOf('jokes/normal/joke') > 0)
	||	(location.href.indexOf('jokes/prog/joke') > 0)) {
		l_title = 'Joke : ' + l_title;
	}

	return 'TC\'s Container' + (((l_title == null) || (l_title == 'TC\'s Container')) ? '' : ' : ' + l_title);
}

function setPageTitle (p_title) {
	document.title = getPageTitle(p_title);
}

function getPageHeader (p_title) {
	return (isNoTitle(p_title) ? document.title : p_title);
}

function PageHeaderBox (p_title, p_button, p_width, p_option, p_hi) {

	if (getMedium() == 'printer') {
		p('<style>.grid{background-color:#ffffff}</style>');
	} else {
		showMenu(p_button, p_option, p_hi);
		p(getPageOpen());
	}

	p(H2(getPageHeader(p_title)));

	setPageTitle(p_title);
}

function PageHeaderBox2 (p_title, p_button) {

	p (
		getTableOpenR(0, 0, 5)
	+	'<td>'
	+	H2(getPageHeader(p_title))
	+	'</td><td valign=top align=right>'
	+	(p_button == null ? '' : p_button)
	+	'</td>'
	+	getTableCloseR()
	+	getPageOpen()
	);
}

function PageHeaderButton (p_level, p_filename, p_target) {

	return	'<a href="'
	+	getPath(p_level)
	+	(p_filename == null ? 'index.htm' : p_filename)
	+	'"'
	+	(p_target == null ? '' : ' target="' + p_target + '"')
	+	'>'
	+	getIconIndex()
	+	'</a>'
}

function PageHeader (p_option, p_hi) {

	PageHeaderBox (
		''
	,	null
	,	null
	,	p_option
	,	p_hi
	);
}

function PageHeaderRSS (p_option, p_xml_file) {

	PageHeaderBox (
		''
	,	ILRSS (
			getIconRSS()
		,	getServerHomeURL() + 'rss/' + p_xml_file
		)
	,	null
	,	p_option
	);
}

function PageFooterLink (p_text, p_url, p_target) {
	return IL(p_text, p_url, null, p_target);
}

function PageFooterLinks (p_links) {
	return '<h5>[ ' + p_links + ' ]</h5>';
}

function PageFooterLinkDiv() {
	return ' | ';
}

function PageFooter (p_links, p_top_link) {

	p (
		(((p_links == null) || (p_links == '')) ? '' : '<p>' + PageFooterLinks(p_links))
	+	getPageClose(null, null, p_top_link)
	);
}

function PageHeaderSoapbox (p_title, p_author, p_date_published, p_date_updated) {

	PageHeaderBox (
		p_title
	,	PageHeaderButton(0)
	);

	p (
		'<font size=-1>'
	+	(p_author == null ? '' : 'Av ')
	+	getAuthor(p_author)
	+	(p_date_published == null ? '' : (p_author == null ? 'P' : ', p') + 'ublisert ' + p_date_published)
	+	(p_date_updated == null ? '' : ', oppdatert ' + p_date_updated)
	+	'</font><p>'
	);
}

function PageHeaderJoke() {

	var l_loc = location.href.substr(location.href.indexOf("jokes/") + 6);
	var l_joke = l_loc.substr(l_loc.indexOf("/") + 5, 4);
	l_loc = l_loc.substr(0, l_loc.indexOf("/"));

	if (l_joke != "") {

		if (l_loc == 'normal') {
			l_highest_joke = 138;
		} else {
			l_highest_joke = 38;
		}

		l_prev_joke = l_joke - 1;
		l_next_joke = l_joke - -1;

		if (l_prev_joke == 0) {
			l_prev_joke = l_highest_joke;
		} else if (l_next_joke > l_highest_joke) {
			l_next_joke = 1;
		}

		l_button = IL(getIconPrev(5), "joke" + lpad(l_prev_joke) + '.htm')
		+	IL(getIconNext(5), "joke" + lpad(l_next_joke) + '.htm')
		;

	} else {

		l_button = '';
	}

	PageHeaderBox(document.title, l_button, null, 'jokes');

}

function PageFooterJoke (p_date_submitted, p_submitter, p_submitter_email) {
	PageFooter(null, 0);
}

function PageHeaderPoem() {
	PageHeaderBox(document.title, null, null, 'poems');
}

function PageFooterPoem (p_translated, p_recorded) {

	var l_loc = location.href.substr(location.href.indexOf("poems/") + 6);
	var l_poem = '';
	var l_rlink = '';
	var l_tlink = '';
	var l_links = '';

	if (location.href.indexOf('english') > -1) {
		l_poem = l_loc.substr(l_loc.indexOf("/") + 5, 4);
	} else {
		l_poem = l_loc.substr(4, 4);
	}

	//p('poem=' + l_poem);

	if (p_translated == 1) {
		if (location.href.indexOf('english') > -1) {
			l_tlink = PageFooterLink('Norwegian', '../poem' + l_poem + '.htm');
		} else {
			l_tlink = PageFooterLink('English', 'english/poem' + l_poem + '.htm');
		}
	}

	if (p_recorded == 1) {
		if (location.href.indexOf('english') > -1) {
			l_rlink = PageFooterLink('Recording', '../poem' + l_poem + '.wav');
		} else {
			l_rlink = PageFooterLink('NRK-opptak', 'poem' + l_poem + '.wav');
		}
	}

	PageFooter(l_rlink + (l_rlink == '' ? '' : PageFooterLinkDiv()) + l_tlink, 0);

}

function getPointer (p_text, p_url, p_extra, p_target) {
	return IL(getIconPointer() + '&nbsp;' + p_text, p_url, p_extra, p_target);
}

function showPointer (p_text, p_url, p_extra, p_target) {
	p(getPointer(p_text, p_url, p_extra, p_target));
}


// text


function B (p_text) {
	return '<b>' + (p_text == null ? '' : p_text) + '</b>';
}


// sections


function H (p_txt, p_size) {
	return '<h' + p_size + '>' + p_txt + '</h' + p_size + '>';
}

function H2 (p_txt) {
	return H(p_txt, 2);
}

function H3 (p_txt) {
	return H(p_txt, 3);
}

function writeH (p_txt, p_size) {
	p(H(p_txt, p_size));
}

function getMovie (p_title, p_id, p_extra) {

	return	'Movie: &quot;<a href="http://www.imdb.com/title/tt'
	+	p_id
	+	'/" target="_blank">'
	+	p_title
	+	'</a>&quot;'
	+	(p_extra == null ? '' : ' ' + p_extra)
	+	'. '
	;
}

function getLoopbackAdapterInstLink() {
	return 	'If your server will have limited network access (e.g. it is a laptop PC), '
	+	'then install and configure the Microsoft Loopback Adapter'
	+	HL('install_loopback_adapter')
	;
}

function writeLoopbackAdapterLinks() {

	writeSectionMoreInfo();

	writeUL (
		LEL('How to Install Microsoft Loopback Adapter in Windows 2000', 'support.microsoft.com/kb/236869')
	+	LEL('How to install the Microsoft Loopback adapter in Windows XP', 'support.microsoft.com/kb/839013')
	+	LEL('How to use the DevCon command-line utility as an alternative to Device Manager', 'support.microsoft.com/kb/311272')
	+	LEL('How to configure a network interface with netsh', 'www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/netsh_int_ip.mspx?mfr=true')
	+	LELCOM('Microsoft', 'microsoft')
	);
}

function getPointer2env (p_version) {
	return getPointer (
		'TC\'s Oracle Application Server environment'
	,	'../ias' + p_version + '/env.htm'
	);
}

function showPointer2env (p_version) {
	p(getPointer2env(p_version));
}

function link2env (p_version, p_type) {

	if (p_version == null) return;

	p (
		'<p><b>Important:</b> Throughout these instructions, you need to replace example paths '
	+	'(e.g. &quot;C:\\ora'
	+	p_version
	+	(p_type == null ? 'mt' : p_type)
	+	'&quot;) with your paths, example instance names (e.g. &quot;ora'
	+	p_version
	+	(p_type == null ? 'mt' : p_type)
	+	'&quot;) with your instance names, and example server names (e.g. '
	+	'&quot;donald.disney.com&quot;) with your server names, '
	+	'unless you actually use similar values as the ones showed here '
	+	'(which makes things much easier'
	+	WL('path')
	+	'). '
	+	'To be on the safe side, avoid using spaces or periods in your permanent and temporary paths!<p>'
	+	(p_type == 'db' ? '' : 'See also ' + getPointer2env(p_version) + '.<p>')
	+	'You should always read the documentation and notes that come with all the '
	+	'products and patches so that you may be prepared for some of the expected '
	+	'and unexpected situations!'
	);
}

function pw_text() {

	p (
		'TC\'s Installation Guides suggest the use of a single superuser password '
	+	'(e.g. <b>welcome1</b>) for the following Oracle users:'
	+	UL (
			LI('<b>sys</b> and <b>system</b> schema users in the database')
		+	LI('<b>ichub</b> and <b>owf_mgr</b> schema users in InterConnect')
		+	LI('<b>ias_admin</b> user in Application Server Control')
		+	LI('<b>orcladmin</b> user in OID')
		+	LI('<b>portal</b> and <b>orcladmin</b> users in Portal')
		+	LI('<b>oc4jadmin</b> user in Application Server 10.1.3 / SOA Suite')
		+	LI('<b>orabpel</b>, <b>oraesb</b>, and <b>orawsm</b> schema users in SOA Suite')
		+	LI('<b>admin</b> user in ' + EL('Apache Tomcat', 'tomcat.apache.org'))
		)
	+	'You should of course use a different password than <b>welcome1</b> which is harder for '
	+	'other users to guess (e.g. <b>roxe8bub</b>).<p>'
	+	'Some Oracle superuser password rules:'
	+	UL (
			LI (
				'The password should conform to the default password policy in OID, '
			+	'i.e. it must have a minimum of 5 alphanumeric characters, it must start with an '
			+	'alphabetical character, and it must contain at least one numeric character.'
			)
		+	LI (
				'The InterConnect components require a password length of 8, so if you would like '
			+	'to use the same superuser password throughout your OracleAS installation, the '
			+	'password should be at least 8 characters long.'
			)
		+	LI (
				'Try to avoid passwords that have a length which is a multiple of 3 (3, 6, 9, 12, etc) - '
			+	'they have been known to cause problems for Web Cache invalidation.'
			)
		)
	+	'<p>'
	);
}

function env_text (p_version, p_type) {

	p (
		'<p>(*) Throughout these instructions, the server name &quot;donald.disney.com&quot; '
	+	'is used - It could just as well have been something like '
	+	'&quot;server1.acme.com&quot;, &quot;www.tcconsulting.com&quot;, '
	+	'&quot;home.tc.no&quot;, etc.'
	+	'<p>As stated earlier, you need to replace paths (e.g. &quot;D:\\ora'
	+	p_version
	+	(p_type == null ? 'mt' : p_type)
	+	'&quot;) with your paths, instance names (e.g. &quot;ora'
	+	p_version
	+	(p_type == null ? 'mt' : p_type)
	+	'&quot;) with your instance names, and server name (e.g. '
	+	'&quot;donald.disney.com&quot;) with your server name.<p>'
	);

	pw_text();

	writeLoopbackAdapterLinks();
}

function writeDisclaimerNote (p_level) {

	writeSectionDisclaimer();

	p (
		'See the '
	+	getPointer('General Disclaimer', getPath(p_level) + 'disclaimer.htm', '.')
	);
}

function writeIntro (p_intro, p_assumptions, p_version, p_type) {

	writeSectionIntro();

	p (
		(p_intro == null ? '' : p_intro)
	+	(p_assumptions == null ? '' : '<p>This guide assumes that:<p>' + UL(p_assumptions))
	);

	link2env(p_version, p_type);

	writeDisclaimerNote(1);
}

function getTableOpen (p_border, p_cellspacing, p_cellpadding, p_width, p_attr) {
	return '<table border='
	+	(p_border == null ? '0' : p_border)
	+	' cellspacing='
	+	(p_cellspacing == null ? '0' : p_cellspacing)
	+	' cellpadding='
	+	(p_cellpadding == null ? '0' : p_cellpadding)
	+	' width='
	+	(p_width == null ? '"100%"' : p_width)
	+	(p_attr == null ? '' : ' ' + p_attr)
	+	'>'
	;
}

function getTableClose() {
	return '</table>';
}

function getTableOpenR (p_border, p_cellspacing, p_cellpadding, p_width, p_attr) {
	return getTableOpen(p_border, p_cellspacing, p_cellpadding, p_width, p_attr) + '<tr>';
}

function getTableCloseR() {
	return '</tr></table>';
}

function getTableRow (p_cells, p_attr) {
	return '<tr' + (p_attr == null ? '' : ' ' + p_attr) + '>' + (p_cells == null ? '' : p_cells) + '</tr>';
}

function writeTableRow (p_cells, p_attr) {
	p(getTableRow(p_cells, p_attr));
}

function getTableCell (p_content, p_attr) {
	return '<td' + (p_attr == null ? '' : ' ' + p_attr) + '>' + (p_content == null ? '&nbsp;' : p_content) + '</td>';
}

function getTableCellVT (p_content, p_attr) {
	return getTableCell(p_content, 'valign=top' + (p_attr == null ? '' : ' ' + p_attr));
}

function getGridTableOpen (p_header_columns) {
	return	'<table border=1 cellspacing=0 cellpadding=3>'
	+	(p_header_columns == null ? '' : getGridTableHeader(p_header_columns))
	;
}

function writeGridTableOpen (p_header_columns) {
	p(getGridTableOpen(p_header_columns));
}

function getGridTableCell (p_content, p_attr) {
	return getTableCell(p_content, 'class="grid" ' + (p_attr == null ? '' : ' ' + p_attr));
}

function getGridTableCellVT (p_content, p_attr) {
	return getGridTableCell(p_content, 'valign=top' + (p_attr == null ? '' : ' ' + p_attr));
}

function getGridTableClose() {
	return '</table>';
}

function writeGridTableClose() {
	p(getGridTableClose());
}

function getGridTableHeader (p_colums) {
	return '<tr>' + p_colums + '</tr>';
}

function writeGridTableHeader (p_colums) {
	p(getGridTableHeader(p_colums));
}

function getGridTableHeaderColumn (p_text, p_attr) {
	return getTableCell(p_text, 'class="gridheader"' + (p_attr == null ? '' : ' ' + p_attr));
}

function getLayoutTableOpen (p_width) {
	return getTableOpen(0, 0, 0, p_width) + '<tr><td valign=top class="bodytext">';
}

function writeLayoutTableOpen (p_width) {
	p(getLayoutTableOpen(p_width));
}

function getLayoutTableNewCol (p_attr) {
	return '</td><td valign=top class="bodytext"' + (p_attr == null ? '' : ' ' + p_attr) + '>';
}

function writeLayoutTableNewCol() {
	p(getLayoutTableNewCol());
}

function getLayoutTableCell (p_content, p_attr) {
	return getTableCell(p_content, 'class="bodytext"' + (p_attr == null ? '' : ' ' + p_attr));
}

function getLayoutTableCellVT (p_content, p_attr) {
	return getLayoutTableCell(p_content, 'valign=top' + (p_attr == null ? '' : ' ' + p_attr));
}

function getLayoutTableClose() {
	return '</td></tr></table>';
}

function writeLayoutTableClose() {
	p(getLayoutTableClose());
}

function getCodeBox (p_code, p_class_suffix) {
	return '<pre class="codebox' + (p_class_suffix == null ? '' : p_class_suffix) + '">' + p_code + '</pre>';
}

function getCmdBox (p_cmd, p_class_suffix) {
	return '<pre class="cmdbox' + (p_class_suffix == null ? '' : p_class_suffix) + '">' + p_cmd + '</pre>';
}

function showCodeBox (p_code, p_class_suffix) {
	p(getCodeBox(p_code, p_class_suffix));
}

function showCmdBox (p_cmd, p_class_suffix) {
	p(getCmdBox(p_cmd, p_class_suffix));
}


// rollover images


function roImage (p_name, p_width, p_height, p_filetype) {
	this.on = new Image (p_width, p_height);
	this.on.src = p_name + '-1.' + p_filetype;
	this.off = new Image (p_width, p_height);
	this.off.src = p_name + '-0.' + p_filetype;
}

function roImageNew (p_name, p_width, p_height, p_filetype) {
	roImage[p_name] = new roImage (
		p_name
	,	p_width
	,	p_height
	,	(p_filetype == null ? 'jpg' : p_filetype)
	);
}

function roImageOn (p_name, p_msg) {
	if (document.images) {
		document[p_name].src = roImage[p_name].on.src;
		window.status = p_msg;
	}
	return true;
}

function roImageOff (p_name) {
	if (document.images) {
		document[p_name].src = roImage[p_name].off.src;
		window.status = '';
	}
	return true;
}

function getroImage (p_name, p_width, p_height, p_filetype, p_text, p_url, p_hspace, p_vspace, p_attr) {

	var l_home = getHomeURL();
	var l_name = l_home + p_name;
	var l_img =	'<img src="'
		+	l_name
		+	'-0.'
		+	p_filetype
		+	'" name="'
		+	l_name
		+	'" border=0 width='
		+	p_width
		+	' height='
		+	p_height
		+	' hspace='
		+	(p_hspace > 0 ? p_hspace : 0)
		+	' vspace='
		+	(p_vspace > 0 ? p_vspace : 0)
		+	' alt="'
		+	p_text
		+	'">'
	;

	return '<a href="'
	+	l_home
	+	p_url
	+	'"'
	+	' onMouseOver="return roImageOn(\'' + l_name + '\', \''
	+	p_text
	+	'\')"'
	+	' onMouseOut="return roImageOff(\'' + l_name + '\')"'
	+	(p_attr == null ? '' : ' ' + p_attr)
	+	'>'
	+	l_img
	+	'</a>'
	;
}


// cookies


function FixCookieDate (date) {

	var base = new Date(0);
	var skew = base.getTime(); // dawn of (UNIX) time - should be 0

	if (skew > 0)  // Except on the Mac - ahead of its time
		date.setTime (date.getTime() - skew);
}

function getCookieVal (offset) {

	var endstr = document.cookie.indexOf (";", offset);

	if (endstr == -1)
		endstr = document.cookie.length;

	return unescape(document.cookie.substring(offset, endstr));
}

function GetCookie (name) {

	var arg = name + "=";
	var alen = arg.length;
	var clen = document.cookie.length;
	var i = 0;

	while (i < clen) {

		var j = i + alen;

		if (document.cookie.substring(i, j) == arg)
			return getCookieVal (j);

		i = document.cookie.indexOf(" ", i) + 1;

		if (i == 0) break; 
	}

	return null;
}

function SetCookie (name, value, expires, path, domain, secure) {

	document.cookie = name
	+	"="
	+	escape(value)
	+	((expires) ? "; expires=" + expires.toGMTString() : "")
	+	((path) ? "; path=" + path : "")
	+	((domain) ? "; domain=" + domain : "")
	+	((secure) ? "; secure" : "")
	;
}
