I\'m trying to modify a Jquery pagination (based on this Jquery pagination tutorial - demo) to work with the awesome twitter bootstrap.
Twitter Bootstrap\'s standard
I totally forgot this post
However i managed to make it work with the following code:
// Based on http://stackoverflow.com/questions/1262919/jquery-active-class-assignment and http://stackoverflow.com/questions/2037501/javascript-add-class-when-link-is-clicked
$(function() {
$('ul.nav li:first').addClass('active').show(); //Activate first tab
$('li a').click(function(e) {
//e.preventDefault();
var $this = $(this);
$this.closest('ul').children('li').removeClass('active');
$this.parent().addClass('active');
//Remove active from dropdown li
$('.dropdown').removeClass('active');
// Activate Home when clicked on the logo
$('.thelogo').click(function()
{
$('.nav li').removeClass('active');
$('.home').addClass('active');
});
});
});