﻿/*
var answ=1;
icon=new Image();
icon.src = "<?php bloginfo('stylesheet_directory'); ?>/image/icon_arrow3.GIF";
menuback=new Image();
menuback.src="<?php bloginfo('stylesheet_directory'); ?>/image/side2-top-4.gif"
*/
$(document).ready(function(){
	
	$(".sendToLinkBox").click(function(){
		
		$("#"+$(this).attr('nav')).toggle();
	});
	$(".titleLinks").click(function(){
		
		$("#"+$(this).attr('con')).toggle();
		
		if($(this).attr('vis')='true'){
			$(this).attr('vis', 'false');
//			$("#"+$(this).attr('logo')).css('margin-top','-25px');
		}
		else {
			$(this).attr('vis', 'true');
//			$("#"+$(this).attr('logo')).css('margin-top','0px');
		}
	});
/*
	uprt = "Shared by  Mohammad Ali ";
	qe="";
//	$("#googleReaderSharedItemsBlick").hide();
	$("#googleReaderSharedItemsBlick > .feedburnerFeedBlock > ul > li > div").each(function(){
		sss = $(this).text();
		qe = sss.substr(0, 24);
		if(qe != uprt) {
			   $(this).css({ display:"none" });
		}
		else {
			end = sss.indexOf('/-/', 0);
			if(end!= (-1)) {
				$(this).text(sss.substr(24, end-24)+' ');
			}	
			else {	
				$(this).css({ display:"none" });
			}
		}
		$("#googleReaderSharedItemsBlick").show();
		
	});
*/
//	$("#googleReaderSharedItemsBlick").html($("#googleReaderBlock").html());
//	$("#DelIcioUsBlick").html($("#DelIcioUsBlick").html()+$("#deliciousBlock").html());
//	$("#googleFriendBlick").html($("#googleFriendBlick").html()+$("#googlefriendBlock").html());

});
/*
function logocloser(stri)
{
	if(answ==1)
	{
		document.getElementById ("ettehad-logo").style.display="none";
		document.getElementById ("tap").src="<?php bloginfo('stylesheet_directory'); ?>/image/icon_arrow3.GIF";
		document.getElementById ("tap").title="نمايش مجدد لوگوي حمايتي"	;		
		answ=answ*(-1);
		return;
	}
	if(answ==-1)
	{
		document.getElementById ("tap").src="<?php bloginfo('stylesheet_directory'); ?>/image/icon_arrow.gif";
		document.getElementById ("ettehad-logo").style.display="";
		document.getElementById ("tap").title="پنهان کردن لوگوي حمايتي";
		answ=answ*(-1);
		return;
	}
	return;
}
function ChangeMenu(i)
{
	document.getElementById ("changable-menu-"+i).style.display="none";
	document.getElementById ("changable-menu-"+(-1)*i).style.display="";
	if(i==1)
		document.getElementById ("side2-content3").className="side2-content3";
	if(i==-1)
		document.getElementById ("side2-content3").className="side2-content4";
	return;
}
function convertfeed(mod){
	if(mod==1) {
		zzz="http://feeds.feedburner.com/~e?ffid=657209";
		document.getElementById ('frrdurl').value=zzz;
		document.getElementById ('frrdtitle').value="Pat.Riot.ir's Post + LinkDumps";
	}
	if(mod==2) {
		zzz="http://feeds.feedburner.com/~e?ffid=1143921";
		document.getElementById ('frrdurl').value=zzz;
		document.getElementById ('frrdtitle').value="Pat.Riot.ir's Post";
	}
}
function showhid(hid_name) {
	if(document.getElementById (hid_name).style.display=="none")
		document.getElementById (hid_name).style.display="";
	else 
		document.getElementById (hid_name).style.display="none";	
	document.getElementById (hid_name).focus();	
	}
var erp=0;
var cld=1;
function sendto(erp) {
	if(cld>0) {
			erp=15;
			sendto_open(erp);
		}
	if(cld<0) {
			erp=300;
			sendto_clode(erp);
	}
}
function sendto_open(erp) {
		if(erp<300) {
			document.getElementById("sendto").style.width=erp;
			erp=erp+10;
			setTimeout ("sendto_open("+erp+")" , 100);
			}
		else {
			cld=cld*(-1);
			return;
			}
	}
function sendto_clode(erp) {
		if(erp>0) {
			document.getElementById("sendto").style.width=erp;
			erp=erp-10;
			setTimeout ("sendto_clode("+erp+")" , 100);
			}
		else {
			cld=cld*(-1);
			return;
			}
	}function showdetails(st) {	document.getElementById("feedetails").innerHTML=st;	}
*/
