/* $(function () {
	var releaseDateus=new Date();
	releaseDateus.setTime(00,00);
	releaseDateus.setFullYear(2009,9,6);
	$('#countdownus').countdown({until: releaseDateus, labels: ['Years', 'Months', 'Weeks', 'Ds', 'Hs', 'Ms', 'Ss'], labels1: ['Year', 'Month', 'Week', 'D', 'H', 'M', 'S']});
});

$(function () {
	var releaseDateuk=new Date();
	releaseDateuk.setTime(00,00);
	releaseDateuk.setFullYear(2009,9,9);
	$('#countdownuk').countdown({until: releaseDateuk, labels: ['Years', 'Months', 'Weeks', 'Ds', 'Hs', 'Ms', 'Ss'], labels1: ['Year', 'Month', 'Week', 'D', 'H', 'M', 'S']});
});
*/
$(function () {
  $(".bar").each(function(){
      var percentage = $(this).next().text();
      $(this).css({width: "0%"}).animate({
				width: percentage}, 'slow');
  });
	});
$(function () {
	$("a.fb").fancybox({
			'padding': 2,
			'imageScale': true,
			'overlayShow':	true,
			'zoomOpacity': false,
			'overlayOpacity': 0.7
	});
	$(".fbvid").fancybox({
			'padding': 4,
			'imageScale': true,
			'overlayShow':	true,
			'zoomOpacity': false,
			'frameWidth': 730,
			'frameHeight': 435,
			'overlayOpacity': 0.7,
			'hideOnContentClick': false
	});
	$("#selectavatar").show();
	$("form#ouravatar input").hide();
	$("form#ouravatar input.bt").show();
});

function selectAvatar(id) {
	$("#ouravatar img").removeClass('selected');
	$("#"+id).addClass('selected');
	$("#"+id).attr("checked", "checked"); 
}
function reply(cid,url){
	$(".replybtshow").hide();
	$("#replydiv"+cid).show();
	$("#replydiv"+cid+" .formdiv").html('<form id="replyform" name="replyform" action="'+url+'" method="post"><textarea cols="" rows="" id="reply" name="comment"></textarea><input type="submit" class="bt" name="submit" value="Reply"/><input type="hidden" name="rcid" value="'+cid+'"/></form>');
	$("#postcomment").hide();
}

function closeReply(cid){
	$(".replybtshow").show();
	$("#replydiv"+cid).hide();
	$("#postcomment").show();
	$(".formdiv").html('');
}