Skip to content

Instantly share code, notes, and snippets.

View stuntbox's full-sized avatar

David Sleight stuntbox

View GitHub Profile
@wolfeidau
wolfeidau / sass_converter.rb
Created May 7, 2011 02:43
Sass plugin for Jekyll
module Jekyll
# Sass plugin to convert .scss to .css
#
# Note: This is configured to use the new css like syntax available in sass.
require 'sass'
class SassConverter < Converter
safe true
priority :low
def matches(ext)
/*
---
name: guilloche
script: guilloche.js
description: guilloche
provides: [Guilloche]
...
*/
@becker1701
becker1701 / post.rb
Created November 19, 2015 18:54
Category slugify plugin for Jekyll 3.0.0: This plugin will slugify the categories listed in the YML frontmatter. Categories with multiple words will have the spaces replaced with dashes. Put this file in the _plugins directory.
module Jekyll
class Document
#Updated for Jekyll 3.0.0
# override post method in order to return categories names as slug
# instead of strings
#
# An url for a post with category "category with space" will be in
@pixelhandler
pixelhandler / index.html
Created October 11, 2010 23:57
Event Pooling example using jQuery
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8"/>
<title>Event Pooling, or perhaps Pub/Sub</title>
<script type="text/javascript" charset="utf-8" src="http://ajax.microsoft.com/ajax/jQuery/jquery-1.4.2.min.js"></script>
</head>
<body>
<strong>Who is this?</strong>
<form action="#" method="get" accept-charset="utf-8" id="whoisit">
@dirtystylus
dirtystylus / wp-remove-text-tab-buttons
Created September 16, 2014 20:35
WordPress Remove Text Tab Buttons
function _remove_quicktags( $qtInit )
{
// Remove only the 'italic', 'bold', and 'block-quote' buttons
$remove_these = array('strong', 'em', 'block', 'link', 'del', 'ins', 'img', 'ul', 'ol', 'li', 'code', 'more', 'close');
// Convert string to array
$buttons = explode(',', $qtInit['buttons']);
// Loop over items to remove and unset them from the buttons
for( $i=0; $i < count($remove_these); $i++ )
{
if( ($key = array_search($remove_these[$i], $buttons)) !== false)