$(document).ready(function(){

	//$("#viewprof").click(function(){
	//	window.location.href = "/pp/<?php echo $member_row['PublicProfileURL']; ?>";
	//	return false;
	//});

	$("#show_all_port").click(function(){
		var checkedVal=this.checked;
 		$('.port_checkbox').each( 
	  		function(){
		  		this.checked=checkedVal;
			});
	});
	$("#show_all_wish").click(function(){
		var checkedVal=this.checked;
 		$('.wish_checkbox').each( 
	  		function(){
		  		this.checked=checkedVal;
			});
	});
	$("a.fav_popup").click(function(event){
		var theID = this.id.substr(4);
		$.get("remove-favorite.php",  { ID: theID } , function(data){
			//$("div#popup_box").fadeIn("slow");
			alert("Your favorite was removed successfully");
			var x = $("#p_fav_"+theID);
			$("#p_fav_"+theID).slideUp();
		});
		return false;
	});

	// for some box effects
	//$("div#popup_box").click(function(event){
	//	$("div#popup_box").hide();
	//});

	//show immediate
	//$("a.fav_popup").click(function(event){
	//		$("div#popup_box").show();
	//});

	//slide
	//$("a.fav_popup").click(function(event){
	//		$("div#popup_box").slideDown("slow");
	//});
});

