﻿function _PrintPage(cotent_ID,Lan)
{
    window.open("/ContentDetailesPrint.aspx?Con_id="+cotent_ID+"&Lan="+Lan);
}
function _PrintPageContactus(Cat_id,Lan)
{
    window.open("/ContentDetailesPrint.aspx?Cat_id="+Cat_id+"&Lan="+Lan);
}
function _OpenMail(cotent_ID,Lan)
{
    window.open("/ContentEmail.aspx?Content_id="+cotent_ID+"&Lan="+Lan,"","toolbar=0,location=0,status=0,menubar=0,scrollbars=0,resizable=0,width=500,height=315");    
}
function _OpenMailContactus(cat_ID,Lan)
{
    window.open("/ContentEmail.aspx?Cat_id="+cat_ID+"&Lan="+Lan,"","toolbar=0,location=0,status=0,menubar=0,scrollbars=0,resizable=0,width=500,height=315");    
}
function _OpenFeedback(cotent_ID,Lan)
{    
    window.open("/Feedback.aspx?Content_id="+cotent_ID+"&Lan="+Lan,"","toolbar=0,location=0,status=0,menubar=0,scrollbars=0,resizable=0,width=500,height=380");
}
function _RatingContent(cotent_ID)
{    
    var IDTD = "TDRating"+cotent_ID;
    if(document.getElementById(IDTD).style.display == "none")
        document.getElementById(IDTD).style.display = "inline";
    else
        document.getElementById(IDTD).style.display = "none";
}
function getQueryVariable(variable) 
{
	var query = window.location.search.substring(1);
	var vars = query.split("&");
	for (var i=0;i<vars.length;i++) {
		var pair = vars[i].split("=");
		if (pair[0] == variable) {
			return pair[1];
		}
	} 
}
function _Pagedateload()
{
    var lan = getQueryVariable("Lan");
    if(lan == "Fa" || lan == "fa")
    {
        document.getElementById("TDDateSEn").style.display = "none";
        document.getElementById("TDDateEEn").style.display = "none";
    }
    else
    {
        document.getElementById("TDDateSFa").style.display = "none";
        document.getElementById("TDDateEFa").style.display = "none";
    }
}
