Skip to content

Instantly share code, notes, and snippets.

module BootstrapPaginationHelper
class LinkRenderer < WillPaginate::ActionView::LinkRenderer
protected
def page_number(page)
unless page == current_page
link(page, page, :rel => rel_value(page))
else
link(page, "#", :class => 'active')
end
var _ga = _ga || {};
var _gaq = _gaq || [];
_ga.trackSocial = function(opt_pageUrl, opt_trackerName) {
twttr.ready(function (twttr) {
_ga.trackTwitter(opt_pageUrl, opt_trackerName);
});
};
_ga.trackTwitter = function(opt_pageUrl, opt_trackerName) {
var trackerName = _ga.buildTrackerName_(opt_trackerName);
try {