var margin = $(obj).parent().parent().find(".slide_content").width();
margin = margin * ($(obj).prevAll().size() - 1);
margin = margin * -1;
$(obj).parent().parent().find(".tabslider").stop().animate({
marginLeft: margin + "px"
}, {
duration: 300
});
}
}
$(document).ready(function() {
TabbedContent.init();
});
</script>
</head>
<body>
<div style='padding: 15px;'>
<div class='content'>
<h1>Tabbed content with jQuery</h1>
<p>
An example of some tabbed content containers.
</p>
<h2>Example:</h2>
<div class='tabbed_content'>
<div class='tabs'>
<div class='moving_bg'>
</div>
<span class='tab_item'>
Latest posts
</span>
<span class='tab_item'>
Top posts
</span>
<span class='tab_item'>
Partners
</span>
<span class='tab_item'>
Links
</span>
</div>
<div class='slide_content'>
<div class='tabslider'>
<ul>
<li>
<a href='#'>
New looks coming your way
</a>
</li>
<li>
<a href='#'>
jQuery convertion: Panoramic Photoviewer in Javascript
</a>
</li>
<li>
<a href='#'>
jQuery convertion: Garagedoor effect using Javascript
</a>
</li>
<li>
<a href='#'>
Image slider for displaying pictures or portfolios
</a>
</li>
<li>
<a href='#'>
AjaxTwits - Load Tweets on your website with AJAX
</a>
</li>
</ul>
<ul>
<li>
<a href='#'>
Panoramic Photoviewer in Javascript
</a>
</li>
<li>
<a href='#'>
New looks coming your way
</a>
</li>
<li>
<a href='#'>
jQuery convertion: Garagedoor effect using Javascript
</a>
</li>
<li>
<a href='#'>
jQuery convertion: Panoramic Photoviewer in Javascript
</a>
</li>
<li>
<a href='#'>
Lightbox + PhotoNav = LightNav
</a>
</li>
</ul>
<ul>
<li>
<a href='#'>
Sieb Design | Design + Illustration
</a>
</li>
<li>
<a href='#'>
Cybox | Internet & Communicatie
</a>
</li>
<li>
<a href='#'>
Hypekid | Pim Arts, a freelance web-developer from the Netherlands
</a>
</li>










