	// JavaScript Document
	function comment(id, type) {
		url = 'comment.php?id=' + id + "&type=" + type;
	//	alert('the url is ' + url); 
		window.open(url,"","scrollbars=yes,scrolling=yes,resizeable=no,width=350,height=400,toolbar=no,location=no");
	}
	
	function picpop(url, width, height) {
		var w=width+20;
		var h=height+27;
		var parms="scrollbars=no,scrolling=no,resizeable=no,width=" + w + ",height=" + h + ",toolbar=no,location=no";
	//	alert(url);
		window.open(url, "", parms);	
	}
	function windowpop(url, width, height) {
		var parms="scrollbars=yes,scrolling=yes,resizeable=no,width=" + width + ",height=" + height + ",toolbar=no,location=no,status=yes";
	//	alert(url);
		window.open(url, "", parms);	
	}
	function edit(opt, id) {
		var url="sadder.php?opt=" + opt + "&id=" + id; 
		var parms="scrollbars=yes,scrolling=yes,resizeable=no,width=500,height=500,toolbar=no,location=no,status=yes";
	//	alert(url);
		window.open(url, "", parms);	
	}
	function ahrefThis() {
		strSelection = document.selection.createRange().text
		if (strSelection == "") {
			document.form1.entry.focus(); 
		}
		strHref = prompt("Enter the URL of the site you to link:","http://");
		if (strHref == null) {
			return;
		}
		document.selection.createRange().text = "<a href=\"" + strHref + "\" target=\"_blank\" class=\"text\">" + strSelection + "</a>"
		return;
	}

	function boldThis(from) {
		strSelection = document.selection.createRange().text
		if (strSelection == "") {
			document.form1.entry.focus()
			if (from == 2) {
				document.form1.entry.select();
			}
			strSelection = document.selection.createRange().text;
			document.selection.createRange().text = strSelection + "<b></b>";
		} 
		else {
			document.selection.createRange().text = "<b>" + strSelection + "</b>";
		}
		return;
	}


	function italicThis() {
		strSelection = document.selection.createRange().text;
		if (strSelection == "") {
			document.form1.entry.focus();
			if (from == 2) {
				document.form1.entry.select();
			}
			strSelection = document.selection.createRange().text;
			document.selection.createRange().text = strSelection + "<i></i>";
		}
		else {
			document.selection.createRange().text = "<i>" + strSelection + "</i>";
		}
		return;
	}
	function more(id) {
		id1=id+'a';
		id2=id+'b';
		document.getElementById(id2).style.display = "block";
		document.getElementById(id1).style.display = "none";
	}
	function less(id) {
		id1=id+'a';
		id2=id+'b';
		document.getElementById(id1).style.display = "block";
		document.getElementById(id2).style.display = "none";	
	}
	/*function pTnail(input) {
		alert("This is the start: " + input); 
		total=input.length-1;
		part1=substring(0, total-4);
		part2=substring(total-4, total);
		output=part1 + "_t" + part2; 
		alert("This is the result: " + output); 
	} */
