Skip to content

Instantly share code, notes, and snippets.

=sprite(!width = 0, !x = 0)
{
width:!width;
& a { background-position:!x 0; }
& a:hover { background-position:!x -34px; }
& a.selected { background-position:!x -68px; }
}
.left_tabs
function Scaffold_hexa2rgba($hex,$alpha=1)
{
$hex = str_replace('#','',$hex);
$r = $g = $b = 0;
switch(strlen($hex)){
case 3:
list($r,$g,$b) = str_split($hex);
$r = hexdec($r.$r);
$g = hexdec($g.$g);
<?php
if ( ! defined('EXT'))
{
exit('Invalid file request');
}
$SERVER_NAME = $_SERVER['SERVER_NAME'];
$SITE_URL = "http://{$SERVER_NAME}";
$ENVIRONMENT = '';
error_reporting(E_ALL & ~E_STRICT ^ E_DEPRECATED);
#form-search input
{
-webkit-appearance:none;
border:1px solid #cfcfcf;
border-right:0;
height:23px;
width:200px;
font:inherit;
float:left;
padding:0 3px;
@anthonyshort
anthonyshort / formalize.css
Created August 9, 2010 02:01
Simple form reset
/*
Form Elements
-- Styled to look like native Safari on OS X.
-- Drop-down <select> menus are unaffected.
-- Buttons are unaffected. Native OS style.
*/
::-webkit-input-placeholder {
color: #000;
}
input,button
{
-webkit-box-sizing:content-box;
-moz-box-sizing:content-box;
box-sizing:content-box;
}
<?php
// Setup the env
$system = '/Users/anthonyshort/Dropbox/Projects/Scaffold/Core/';
include $system.'/lib/Scaffold/Environment.php';
Scaffold_Environment::auto_load();
// Configuration
$config = array(
'extensions' => array(
RewriteEngine on
DirectorySlash off
DirectoryIndex index.html index.cgi
# do not mess with the subdomains
# (I’ve named them with folders starting with “_”)
RewriteRule ^_ - [L]
# this ‘feature’ drove me absolutely insane!
# without this, Apache will give a 404 for a rewrite if a folder of the same name does not exist (e.g. “/blog/hello”)
<?php
/**
* Scaffold_Extension_Template
*
* Make a copy of this file and directory for your own extensions
*
* @package Scaffold
* @author Anthony Short <anthonyshort@me.com>
* @copyright 2009-2010 Anthony Short. All rights reserved.
* @license http://opensource.org/licenses/bsd-license.php New BSD License