/*  本 js 已不用，故清除之
/*--------------------------------------------------------------------------*/
$(document).ready(function(){
	
	/*隱藏新聞轉寄功能*/
	$("#news_act li:first").css({"display":"none"});
	

	/*下拉bar關閉*/
	$(document).ready(function(){
		$("body").click(function(){
			$("#newsflash").hide();
		 });
	});
	
	//按這裡檢視圖片
	$(".view-photo").click(function(){
		var phtoURL = $(this).attr("rel");
		$(this).attr("src",phtoURL);
		$(this).css("cursor","default");
	})
		
	//檢視所有圖片
	$(".view-all").click(function(){
		$(".view-photo").each(function(index){
			var phtoURL = $(this).attr("rel");
			$(this).attr("src",phtoURL);
		})
		$(".view-all").hide();
	})
		
	//照片頁加攝影記者頭像
	var photoman_1 ='<hr style="clear:both;"/><div style="float:left;margin:5px;"><a href="http://www.facebook.com/profile.php?id=100001547649219" target="_blank" title="攝影記者／邱榮吉"><img src="http://www.nownews.com/newspic/1698/i1698779.jpg" width="50" height="50" alt="攝影記者／邱榮吉"/></a><br/><span>邱榮吉</span></div>';
	var photoman_2 ='<hr style="clear:both;"/><div style="float:left;margin:5px;"><a href="http://www.facebook.com/profile.php?id=100000068483128" target="_blank" title="攝影記者／朱家彥"><img src="http://graph.facebook.com/100000068483128/picture" width="50" height="50" alt="攝影記者／朱家彥"/></a><br/><span>朱家彥</span></div>';
	
	var isPhotoman_1 = $("#photo_box p:contains('邱榮吉')").length;
	var isPhotoman_2 = $("#photo_box p:contains('朱家彥')").length;
	
	if (isPhotoman_1 == "1") {//邱榮吉
		$("#photo_box p").before(photoman_1);
	}
	if (isPhotoman_2 == "1") {//朱家彥
		$("#photo_box p").before(photoman_2);
	}

});
