2011-05-03 10:36:26 -04:00
|
|
|
/*
|
2011-05-20 12:39:44 -04:00
|
|
|
* Skeleton V1.0.2
|
2011-05-19 15:05:30 -04:00
|
|
|
* Copyright 2011, Dave Gamache
|
2011-05-15 20:02:52 -04:00
|
|
|
* www.getskeleton.com
|
2011-05-19 15:05:30 -04:00
|
|
|
* Free to use under the MIT license.
|
|
|
|
* http://www.opensource.org/licenses/mit-license.php
|
2011-05-20 12:39:44 -04:00
|
|
|
* 5/20/2011
|
2011-05-03 10:36:26 -04:00
|
|
|
*/
|
2011-05-04 21:20:56 -04:00
|
|
|
|
2011-05-02 15:17:18 -04:00
|
|
|
|
2011-05-01 11:43:13 -04:00
|
|
|
$(document).ready(function() {
|
|
|
|
|
2011-05-03 10:36:26 -04:00
|
|
|
/* Tabs Activiation
|
|
|
|
================================================== */
|
2011-05-16 21:03:36 -04:00
|
|
|
var tabs = $('ul.tabs'),
|
|
|
|
tabsContent = $('ul.tabs-content');
|
2011-05-01 11:43:13 -04:00
|
|
|
|
|
|
|
tabs.each(function(i) {
|
|
|
|
//Get all tabs
|
2011-05-17 20:54:18 -04:00
|
|
|
var tab = $(this).find('> li > a');
|
2011-05-01 11:43:13 -04:00
|
|
|
tab.click(function(e) {
|
|
|
|
|
|
|
|
//Get Location of tab's content
|
2011-05-17 20:54:18 -04:00
|
|
|
var contentLocation = $(this).attr('href') + "Tab";
|
2011-05-01 11:43:13 -04:00
|
|
|
|
|
|
|
//Let go if not a hashed one
|
|
|
|
if(contentLocation.charAt(0)=="#") {
|
|
|
|
|
|
|
|
e.preventDefault();
|
|
|
|
|
|
|
|
//Make Tab Active
|
|
|
|
tab.removeClass('active');
|
|
|
|
$(this).addClass('active');
|
|
|
|
|
|
|
|
//Show Tab Content
|
2011-05-17 20:54:18 -04:00
|
|
|
$(contentLocation).show().siblings().hide();
|
2011-05-01 11:43:13 -04:00
|
|
|
|
|
|
|
}
|
|
|
|
});
|
2011-05-03 10:36:26 -04:00
|
|
|
});
|
2011-05-01 11:43:13 -04:00
|
|
|
|
|
|
|
});
|