Skip to content

Instantly share code, notes, and snippets.

@mohit-rocks
mohit-rocks / gist:7d43ec7585b89a00bf4c
Created November 9, 2015 12:58 — forked from robertmarsal/gist:9feaa9150926efa4175a
Install f.lux on Ubuntu 14.10
sudo apt-get install python-glade2 python-appindicator
git clone https://github.com/Kilian/f.lux-indicator-applet.git
cd f.lux-indicator-applet
chmod +x setup.py
sudo ./setup.py install
fluxgui
@mohit-rocks
mohit-rocks / infinitescrollajax.js
Created October 11, 2014 14:07
Infinite pager without infinitescroll.js [Drupal] [Apache solr page] Ref : https://www.drupal.org/node/1473558#comment-8597229
/**
* Js file to add load more button on the search result page.
*/
(function ($) {
Drupal.behaviors.loadMoreAjax = {
attach: function (context, settings) {
$('.load-more-ajax', context).click(function () {
var nextPage = $('.pager .pager__item--next a').attr('href');
var lastPage = $('.pager .pager__item--last a').attr('href');
@mohit-rocks
mohit-rocks / date-views-pager.tpl.php
Created February 11, 2014 04:55
override the pager title for the calendar(Drupal 7)
<?php
/**
* @file
* Template file for the example display.
*
* Variables available:
*
* $plugin: The pager plugin object. This contains the view.
*
* $plugin->view