Skip to content

Instantly share code, notes, and snippets.

@jackilyn
jackilyn / gist:1602933
Created January 12, 2012 20:34
Stack of Papers CSS
body {
background: #666;
}
.papers {
background-color: white;
height: 350px;
padding: 20px;
width: 260px;
-webkit-box-shadow:
1px 1px 0 rgba(0, 0, 0, 0.100),
@jackilyn
jackilyn / gist:1602942
Created January 12, 2012 20:35
WordPress style.css Template
/*
Theme Name:
Theme URI: http://
Description:
Author:
Author URI: http://
Version:
Tags:
License:
@jackilyn
jackilyn / adjacent.css
Created January 12, 2012 20:40
CSS Selectors
/* Adjacent Selector
* It will select only the element that is immediately preceded by the former element.
* ------------------------------ */
/* First preceding element only */
ul + p {
color: red;
}
/* All preceding elements */
h1 ~ p {
@jackilyn
jackilyn / gist:1621915
Created January 16, 2012 17:28
CSS Page Curl
.page-curl {
position: relative;
background: #ffffff;
background: -moz-linear-gradient(top, #ffffff 0%, #e5e5e5 100%);
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#ffffff), color-stop(100%,#e5e5e5));
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#e5e5e5',GradientType=0 );
-webkit-box-shadow: 0px 0px 3px rgba(0, 0, 0, 0.3);
-moz-box-shadow: 0px 0px 3px rgba(0, 0, 0, 0.3);
}
@jackilyn
jackilyn / gist:1690776
Created January 27, 2012 20:32
Half & Half
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Half &amp; Half</title>
<style type="text/css">
* {
margin: 0;
@jackilyn
jackilyn / get-url-variables.js
Created January 27, 2012 20:38
Get Variables from URLs
function getQueryVariable(variable) {
var query = window.location.search.substring(1);
var vars = query.split("&");
for (var i=0;i<vars.length;i++) {
var pair = vars[i].split("=");
if (pair[0] == variable) {
return pair[1];
}
}
@jackilyn
jackilyn / gist:1990542
Created March 7, 2012 02:40
New Image Replacement
// from http://www.zeldman.com/2012/03/01/replacing-the-9999px-hack-new-image-replacement/
.hide-text {
text-indent: 100%;
white-space: nowrap;
overflow: hidden;
}
@jackilyn
jackilyn / launch-sublime-from-terminal.md
Last active October 1, 2015 20:37
Launch Sublime Text 2 from the Mac OS X Terminal

Launch Sublime Text from the Mac OS X Terminal

Create a symlink called sublime: ln -s /Applications/Sublime\ Text.app/Contents/SharedSupport/bin/subl /usr/local/bin/sublime

Check to see if /usr/local/bin is in your PATH: open ~/.zshrc

Make sure it says: export PATH=/usr/local/bin:/example/other/dirs/

@jackilyn
jackilyn / gist:2178803
Created March 24, 2012 05:52
Wordpress Page Template Identifier
<?php
/*
Template Name: Snarfer
*/
?>
@jackilyn
jackilyn / style-guide.css
Created March 30, 2012 22:44
Comments Style Guide
/*
* Filename
* Description of the file and its contents. Sometimes followed by a
* table of contents.
*
* Maximum Line Length = 70 chars
*
* --------------------------------------------------------------- */
/* Section Heading