function Bookmark() {

	var title = document.title;
	var src = document.location;

	if ((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion) >= 4)) {
		window.external.AddFavorite(src,title);
  	} 
	else if (navigator.appName == "Netscape") {
    	window.sidebar.addPanel(title,src,"");
	}
	else if (window.opera && window.print) {
		var elem = document.createElement('a');
		elem.setAttribute('href', src);
		elem.setAttribute('title', title);
		elem.setAttribute('rel', 'sidebar');
		elem.click();
	}

}

function ValidateEmail(email_1, email_2) {

	if ((email_1.indexOf(".") > 2) && (email_1.indexOf("@") > 0) && (email_1 == email_2)) {
		return true;
	}
	else {
		alert('Please make sure you have entered a valid email address and that the two email boxes match.');
		return false;
	}

}

function showLargeImage(src) {
	var e = document.getElementById('large-image');
	e.src = src.replace('-thumb', '');
}

function autofitIframe(id){
	if (!window.opera && !document.mimeType && document.all && document.getElementById){
		newHeight = this.document.body.offsetHeight + 100;
		parent.document.getElementById(id).style.height=newHeight+"px";
	}
	else if(document.getElementById) {
		newHeight = this.document.body.scrollHeight + 100;
		parent.document.getElementById(id).style.height=newHeight+"px"
	}
} 
