Skip to content

Instantly share code, notes, and snippets.

View korthjp17's full-sized avatar

Jason Korth korthjp17

View GitHub Profile
<?php
public function CurrentLevel() {
$page = $this->owner;
$level = 1;
while(1) {
if($page->Parent) {
$level++;
$page = $page->Parent();
}else {
@lunelson
lunelson / gulpfile.js
Last active February 9, 2018 11:20
Gulp Config to strip Sass comments
//////////////////
// definitions //
//////////////////
var gulp = require('gulp');
var sass = require('gulp-sass');
var strip_comments = require('gulp-strip-json-comments');
//////////
// sass //
@arielsalminen
arielsalminen / endlessPagination.js
Created May 8, 2012 10:08
Custom endless pagination for isotope (supports query strings in url and updates the page count after each load)
jQuery(function () {
var $feed = $(".feed"),
$trigger = $(".next_page"),
$spinner = $(".spinner"),
spinner = "<div class=\"spinner\"></div>";
var isotopeSettings = {
itemSelector: ".box"
}