function feedback(){
window.open("http://www.kampyle.com/feedback_form/ff-feedback-form.php?site_code=4775144&amp;form_id=3386&amp;lang=en", "", "scrollbars=no,height=450,width=440")
}
function GetXmlHttpObject(){
var xmlHttp=null; try{xmlHttp=new XMLHttpRequest();}catch (e){try{
xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");} catch (e){
xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");}}return xmlHttp;}
function show(id){
if (document.getElementById(id).style.display == "block") document.getElementById(id).style.display = "none";
else document.getElementById(id).style.display = "block";}
function poster(pValue){window.open("http://www.post2share.com/common/posters?q=" + pValue);}function amz(pValue){window.open("http://www.post2share.com/common/amz?q=" + pValue);}
sharethis='&nbsp;&nbsp;&nbsp; <script type="text/javascript" src="http://w.sharethis.com/widget/?tabs=web%2Cemail%2Cpost&amp;charset=utf-8&amp;services=%2Cfacebook%2Cmyspace%2Cyahoo_bmarks%2Cdigg%2Cyahoo_myweb%2Cdelicious%2Cgoogle_bmarks%2Creddit%2Cwindows_live%2Cstumbleupon%2Ctechnorati%2Cnewsvine%2Cpropeller%2Cfriendfeed%2Cxanga%2Cmixx%2Cblinklist%2Cfurl&amp;style=default&amp;publisher=96886aba-4a6d-43dc-a6e3-22bdab26967d&amp;headerbg=%23BCCDDB&amp;inactivebg=%23a19b9b&amp;embeds=true"></script>';
function inputi(object, txt){
	if(object.value == txt) {object.value = '';}
}
function inputo(object, txt){
	if (object.value == '') {object.value = txt;}
}
function trimString(pString){
	if (pString){
		pString = pString.replace(/^\s+/g, "");
		return pString.replace(/\s+$/g, "");
	}
}
function cq() {
	var txt = document.getElementById("comment");
	if (!txt.value || trimString(txt.value).length == 0 || txt.value.indexOf('type comments + quotes here...') >= 0){
		document.getElementById("comment").style.border = "1px solid #ff0000";
		return;
	}
	else{
		document.getElementById("comment").style.border = "1px solid #777";
	}						
	if (txt.value.length > 1000)
		document.getElementById("comment").value = document.getElementById("comment").value.substring(0,999);
	var params = "name=" + document.getElementById("name").value + "&web=" + document.getElementById("web").value + 
				 "&comment=" + document.getElementById("comment").value +
				 "&sid=" + Math.random() + "&href=" + window.location.href
	
	document.getElementById("submitid").innerHTML = "<img src='../assets/indicator.gif' style='vertical-align:bottom;' /> Sending ...";
	lXmlHttp = GetXmlHttpObject();
	lXmlHttp.open("POST", "../comment/", true)
	lXmlHttp.onreadystatechange = stateChangedCq
	lXmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
	lXmlHttp.setRequestHeader("Content-length", params.length);
	lXmlHttp.setRequestHeader("Connection", "close");
    lXmlHttp.send(params)
}
function stateChangedCq() {
   	if (lXmlHttp.readyState == 4 || lXmlHttp.readyState == "complete"){
   		var res = lXmlHttp.responseText;
   		document.getElementById("submitid").innerHTML = '<a href="javascript:void(0);" onclick="cq();"><img src="../assets/button_send.gif"/></a>';
   		document.getElementById("comment").value = '';
   		if (res == "" || res.indexOf("cpanel21") < 0) res="";
   		else if (document.getElementById("cpanelscroll")) document.getElementById("cpanelscroll").innerHTML = res + document.getElementById("cpanelscroll").innerHTML;
   		else document.getElementById("cpanel2").innerHTML = res + document.getElementById("cpanel2").innerHTML;
   	}
}
function cpanel0()
{
 	document.getElementById("cpanel0").style.display = "";
	document.getElementById("cpanel0").innerHTML = '<h2 class="cq">Comments &amp; Quotes</h2><table cellspacing="0" cellpadding="0" id="cpanel1"><tr><td style="width:450px;padding:0px 0px 1px 10px;">'+
		      '<input id="name" type="text" name="name" value="name" maxlength="32" style="width:150px;" onfocus="inputi(this, \'name\');" onblur="inputo(this,\'name\');"/>&nbsp;&nbsp;'+
		      '<input id="web" type="text" name="web" value="website (optional)" maxlength="128" style="width:250px;" onfocus="inputi(this, \'website (optional)\');" onblur="inputo(this,\'website (optional)\');"/>'+
		   '</td><td style="vertical-align:middle;padding:0px 0px 1px 10px;" id="submitid"><a href="javascript:void(0);" onclick="cq();"><img src="../assets/button_send.gif" alt=""/></a>'+
		   '</td></tr><tr><td colspan="2" style="padding:0px 0px 0px 10px;">'+
		      '<textarea id="comment" name="comment" rows="2" onfocus="inputi(this, \'type comments + quotes here...\');" onblur="inputo(this,\'type comments + quotes here...\');">type comments + quotes here...</textarea>'+
		    '</td></tr></table>';
}


  					
				   

				  
