Skip to content

Instantly share code, notes, and snippets.

View freekrai's full-sized avatar

Roger Stringer freekrai

View GitHub Profile
@freekrai
freekrai / backbone.behaviour.js
Created March 9, 2012 22:30 — forked from Qard/backbone.behaviour.js
Behaviour abstraction system for backbone.js
!function (Backbone) {
// Store blank stuff here
var blankEl = $()
, blankModel = new Backbone.Model.extend()
, blankCollection = new Backbone.Collection.extend({
model: blankModel
})
, blankView = new Backbone.View.extend({
el: blankEl
})
@freekrai
freekrai / gist:1112482
Created July 28, 2011 20:32 — forked from chriscoyier/gist:945619
commentgraph.php
<?php
/*
Template Name: Comment Graph
*/
?>
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8>
// Plugin
$.fn.iWouldLikeToAbsolutelyPositionThingsInsideOfFrickingTableCellsPlease = function() {
var $el;
return this.each(function() {
$el = $(this);
var newDiv = $("<div />", {
"class": "innerWrapper",
"css" : {
"height" : $el.height(),
"width" : "100%",