This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env php | |
<?php | |
if( ! function_exists( 'inotify_init' ) ) { | |
die_with_error( 'This script needs the inotify module' ); | |
} | |
// usage: $0 path [path ...] -- command | |
$args = $_SERVER['argv']; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// create list of unused stylesheet rules | |
$(document).ready(function() | |
{ | |
var sel = []; | |
for( var s = 0 ; s < document.styleSheets.length ; s++ ) { | |
var rules = document.styleSheets[s].cssRules || document.styleSheets[s].rules; | |
for( var r = 0 ; r < rules.length ; r++ ) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# php 5.3 snow leopard | |
# need 64 bit mysql as /usr/local/mysql | |
# compile apache | |
./configure --enable-layout=Darwin --enable-mods-shared=all | |
make | |
sudo make install | |
# now configure php. then make; sudo make install |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CFLAGS="-arch x86_64" \ | |
./configure \ | |
--with-apxs2=/usr/sbin/apxs --prefix=/usr/local/php5.2.8 --with-config-file-scan-dir=/usr/local/php5.2.8/php.d \ | |
--with-config-file-path=/usr/local/php5.2.8/php.d \ | |
--disable-posix \ | |
--enable-cli \ | |
--with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config \ | |
--with-jpeg-dir=/opt/local/include --with-png-dir=/opt/local/include --enable-gd-native-ttf --with-freetype-dir=/usr/local/php5.2.8 \ | |
--with-zlib \ | |
--enable-pdo --with-pdo-sqlite --with-sqlite=shared --enable-sqlite-utf8 \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Iamstef = Iamstef || {}; | |
(function(lib){ | |
var url = document.URL, | |
api = {}; | |
api.path = function(regex,fcn){ | |
var result = url.match(regex); | |
if(result){ | |
fcn(result); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function randomColor() { | |
var color = (0xffffff * Math.random()).toString(16); | |
return "#" + color.replace(/\./i,"").slice(0,6); | |
}; | |
function fallbackFor(arg, fallback) { | |
return (typeof arg !== 'undefined') ? arg : fallback; | |
} | |
function require(arg, name) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// collapse table sections | |
$(document).ready(function() { | |
$('tbody:has(th)').addClass('collapse') | |
.find('tr:first-child th') | |
.wrapInner('<a href="#"></a>') | |
.find('a') | |
.click(function() { | |
var $thisLink = $(this); | |
$thisLink |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# --- Version history --- | |
# 0.4: added variable to store file path, and $2 for base file name | |
# added variable to store desired reporting interval | |
# 0.3: added $1 to send in process ID at run time. | |
# 0.2: switched to $SECONDS for the loop. works. | |
# 0.1: didn't work well at all. | |
# --- Version history --- | |
# Usage: cputrack [PID] [filename] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* `Rounded Corners | |
----------------------------------------------------------------------------------------------------*/ | |
.round_all { | |
border-radius: 5px; | |
-moz-border-radius: 5px; | |
-webkit-border-radius: 5px; | |
} | |
.round_top { |
OlderNewer