Learn how to use jQuery at the Blog

RocketBoots « visit

  • Added 5 months ago
  • 73 Lines of Code shown
  • 3 Links of Interest
http://rocketboots.com
This is my Source Code and I don't want to show it here
View Source Code only (as overlay)
// That code snippet belongs to RocketBoots - http://rocketboots.com

$(function(){
	$("#sidebar > ul > li > ul").hide();
	$("#sidebar > ul > li").hoverIntent({
		sensitivity:3,
		interval:200,
		timeout:1000,
		over:function(){
			$(this).children("ul").slideDown(300);
		},
		out:function(){
			$(this).children("ul").slideUp(300);
		}
	});
	
	$("#sidebar > ul > li > a").hoverIntent({
		sensitivity:3,
		interval:100,
		timeout:500,
		over:function(){
			$(this).animate({
				backgroundPosition:"-196px 0px",
				paddingLeft: "35px",
				color: "#D1E4F1"
			},200);
		},
		out:function(){
			$(this).animate({
				backgroundPosition:"0px 0px",
				paddingLeft: "25px",
				color: "#444455"
			},200)
		}
	});
	

	$("#sidebar li li").bind('mouseenter',function(){
		$(this).animate({
			paddingLeft: "25px",
		},300);
	});	
	$("#sidebar li li").bind('mouseleave',function(){
		$(this).animate({
			paddingLeft: "10px",
		},300);
	});	
	
//	$("#nav").accordion({
//		autoHeight:false,
//		event:"mouseenter"
//	});
	
	dp.SyntaxHighlighter.ClipboardSwf = '/site/scripts/clipboard.swf';
	dp.SyntaxHighlighter.HighlightAll('code');
	
})




$(function(){
	$(".hor-layout").each(function(){
		var $this = $(this);
		var $horLayoutTable = $("<table class='layout-hor-table'><tbody><tr></tr></tbody></table>");
		var $tableRows = $horLayoutTable.find("tr");
		$tableRows.append($this.children().remove());
		$tableRows.children().wrap("<td></td>");
		$this.append($horLayoutTable);
		if($this.hasClass("hor-balloon")){
			$horLayoutTable.css({width:"100%"});
		}
	});
	
})