var table_url = "../../";
var member_path = "../../member/";
var home_path = "../../../";
var def_title = "Heart Animal Hospital";
var y_delimiter = '';
var y_spacer = '';
var y_table_title_bg_col = "#ffffa0";
var y_table_item_bg_col = "#fffff0";
var y_prologue_col = "#00ffff";
var y_point_image = "red-pin.gif";

function y_set_prologue_col(col) {
	y_prologue_col = col;
}

function y_set_delimiter(image) {
	y_delimiter = image;
}

function y_set_spacer(image) {
	y_spacer = image;
}

function y_delimit(dot) {
	document.write('<img src="',y_delimiter,'" height="',dot,'" width="100%"><br>');
}

function y_space(dot) {
	document.write('<img src="',y_spacer,'" height="',dot,'" width="100%"><br>');
}

function y_blockquote_start() {
	document.write('<blockquote>',"\n");
}

function y_blockquote_end() {
	document.write('</blockquote>',"\n");
}

function y_embed_html_title() {
	if( y_title_text == '' ) {
		document.write('<title>',def_title,'</title>',"\n");
	} else {
		document.write('<title>',y_title_text,'</title>',"\n");
	}
}

function y_embed_html_body() {
	if( y_bg_image == '' ) {
		document.write('<body text="',y_text_col,'" bgcolor="',y_bg_col,'">',"\n");
	} else {
		document.write('<body text="',y_text_col,'" bgcolor="',y_bg_col,'" background="',table_url,'image/bg/',y_bg_image,'">',"\n");
	}
}

function y_disp_title() {
	if( y_title_text ) {
		header(y_title_text,home_path);
	}
}

function y_disp_prologue() {
	if( y_prologue == "" ) {
		return true;
	}
	document.write('<center>');
	document.write('<font size="',y_text_size,'" color="',y_prologue_col,'">');
	document.write(y_prologue);
	document.write('</font><br>');
	document.write('</center>');
}

function y_disp_epilogue() {
	if( y_epilogue == "" ) {
		return true;
	}
	document.write('<center>');
	document.write('<font size="',y_text_size,'" color="',y_text_col,'">');
	document.write(y_epilogue);
	document.write('</font><br>');
	document.write('</center>');
}

function y_disp_footer() {
	document.write('<hr>');
	document.write('<div align="right">');
	document.write('<font size="2" color="#000000">');
	document.write(y_footer_title,' ');
	document.write('</font>');
	document.write('<font size="1" color="#000000">');
	document.write(y_footer_text,'<br>');
	document.write('<a href="',y_footer_link,'" target="_blank">URLi',y_footer_link,'j</a><br>');
	if( y_footer_mailto != "" ) {
		document.write('<a href="mailto:',y_footer_mailto,'">ƒ[ƒ‹i',y_footer_mailto,'j</a><br>');
	}
	document.write("Created:",y_footer_created," ");
	document.write("Updated:",y_updated,"<br>");
	created = y_footer_created.split('/');
	updated = y_updated.split('/');
	if( created[0] == updated[0] ) {
		yy = created[0];
	} else {
		yy = created[0] + "-" + updated[0];
	}
	document.write("Copyright(c) ",yy," ",y_footer_copyright);
	document.write('</font>');
	document.write('</div>');
}

function y_item(attri,yyyy,mm,dd,title,subtitle,url,bannerlink,comment,ex) {
	this.attri = attri;
	this.yyyy = yyyy;
	this.mm = mm;
	this.dd = dd;
	this.title = title;
	this.subtitle = subtitle;
	this.url = url;
	this.bannerlink = bannerlink;
	this.comment = comment;
	this.ex = ex;
}

var y_content = new Array();
var y_item_num = 0;
var y_w_max = 0;

function y_set_item(attri,year,month,day,title,subtitle,url,bannerlink,comment,ex) {
	newobj = new y_item(attri,year,month,day,title,subtitle,url,bannerlink,comment,ex);
	y_content[y_item_num++] = newobj;
}

function y_disp_contents() {
	y_w_max = 0;
	document.write('<table border="',y_image_frame,'" cellpadding="4" cellspacing="0" align="center">');
	for(i=0;i<y_item_num;i++) {
		if( y_content[i].attri == 'info' ) {
			y_disp_info_item(y_content[i]);
		} else if( y_content[i].attri == 'delimiter' ) {
			y_disp_delimiter(y_content[i]);
		}
	}
	document.write('</table>');
}

function y_disp_info_item(obj) {
	document.write('<tr>');
	document.write('<th colspan="2" height="3">');
	document.write('</th>');
	document.write('<tr>');
	document.write('<td bgcolor="',y_table_title_bg_col,'" width="16">');
	document.write('<img src="',table_url,'image/ornament/',y_point_image,'">');
	document.write('</td>');
	document.write('<th bgcolor="',y_table_title_bg_col,'" align="left">');
	if( obj.url != "" ) {
		document.write('<a href="',obj.url,'" target="_blank">');
		document.write('<font size="',y_image_title_size,'" color="',y_image_title_col,'">');
		document.write('<b>',obj.title,'</b>');
		document.write('</font>');
		document.write('</a>');
	} else {
		document.write('<font size="',y_image_title_size,'" color="',y_image_title_col,'">');
		document.write('<b>',obj.title,'</b>');
		document.write('</font>');
	}
	document.write('<td bgcolor="',y_table_title_bg_col,'" width="16" halign="right">');
	document.write('<img src="',table_url,'image/ornament/',y_point_image,'">');
	document.write('</td>');
	document.write('</th>');
	document.write('</tr>');

	document.write('<tr>');
	if(obj.subtitle) {
		document.write('<td nowrap>');
		document.write(obj.subtitle);
		document.write('</td>');
		document.write('<td bgcolor="',y_table_item_bg_col,'" colspan="2">');
	} else {
		document.write('<td colspan="3" bgcolor="',y_table_item_bg_col,'">');
	}
	document.write('<font size="',y_comment_size,'" color="',y_comment_col,'">');
	document.write(obj.comment);
	document.write('</font>');
	document.write('</td>');
	document.write('</tr>');
}

function y_disp_delimiter(obj) {
	document.write('<br>');
	document.write('<img src="',y_delimiter,'" height="1" width="100%"><br>');
	document.write('<center>');
	document.write('<font size="3" color="',y_title_col,'">');
	document.write(obj.title,'<br>');
	document.write('</font>');
	document.write('</center>');
	document.write('<img src="',y_delimiter,'" height="1" width="100%"><br>');
	document.write('<br>\n');
}

function y_control(id) {
	top.i_table_id = id;
	document.write('<div align="right">');
	document.write('<a href="',member_path,'add.htm" target="work"><font size="1" color="#000000">’Ç‰Á</font></a> ');
	document.write('<a href="',member_path,'permutation.htm" target="work"><font size="1" color="#000000">‡˜</font></a> ');
	document.write('<a href="',member_path,'proof.htm" target="work"><font size="1" color="#000000">C³</font></a> ');
	document.write('<a href="',member_path,'deletion.htm" target="work"><font size="1" color="#000000">Á‹Ž</font></a> ');
	document.write('<a href="',member_path,'env.htm" target="work"><font size="1" color="#000000">ŠÂ‹«</font></a> ');
	document.write('<a href="',member_path,'prologue.htm" target="work"><font size="1" color="#000000">˜•¶</font></a> ');
	document.write('<a href="',member_path,'epilogue.htm" target="work"><font size="1" color="#000000">Œ‹•¶</font></a> ');
	document.write('<a href="',member_path,'footer.htm" target="work"><font size="1" color="#000000">’˜ì</font></a> ');
	document.write('<br>');
	document.write('</div>');
}


