Skip to content

Instantly share code, notes, and snippets.

View chriscoyier's full-sized avatar

Chris Coyier chriscoyier

View GitHub Profile
@chriscoyier
chriscoyier / dabblet.css
Created January 26, 2012 16:11 — forked from LeaVerou/dabblet.css
CSS3 demo: City by night
/**
* CSS3 demo: City by night
* Multiple backgrounds, basic linear gradients
*/
html, body {
height: 100%;
}
html {
@chriscoyier
chriscoyier / dabblet.css
Created February 22, 2012 19:19 — forked from anonymous/dabblet.css
pseudo element as background-size
/* pseudo element as background-size */
* {
margin: 0;
padding: 0;
}
p {
position: relative;
height: 400px;
font-size: 100px;
@chriscoyier
chriscoyier / dabblet.css
Created February 22, 2012 19:22 — forked from anonymous/dabblet.css
pseudo element as background-size
/* pseudo element as background-size */
* {
margin: 0;
padding: 0;
}
p {
position: relative;
height: 400px;
font-size: 100px;
@chriscoyier
chriscoyier / dabblet.css
Created February 22, 2012 19:22 — forked from anonymous/dabblet.css
pseudo element as background-size
/* pseudo element as background-size */
* {
margin: 0;
padding: 0;
}
p {
position: relative;
height: 400px;
font-size: 100px;
@chriscoyier
chriscoyier / dabblet.css
Created February 22, 2012 19:22 — forked from anonymous/dabblet.css
pseudo element as background-size
/* pseudo element as background-size */
* {
margin: 0;
padding: 0;
}
p {
position: relative;
height: 400px;
font-size: 100px;
@chriscoyier
chriscoyier / dabblet.css
Created February 24, 2012 03:56 — forked from telic/dabblet.css
Lined Paper
/**
* Lined Paper
*/
html {
background-color:white;
padding:10px;
font-family:sans-serif; font-size:15px;
}
body {
@chriscoyier
chriscoyier / dabblet.css
Created February 29, 2012 18:55 — forked from JosephSilber/dabblet.css
CSS Pac-Man BUG IN CHROME 17 WINDOWS
/* CSS Pac-Man BUG IN CHROME 17 WINDOWS */
#pacman {
width: 0;
height: 0;
border: 60px solid red;
border-right-color: transparent;
border-radius: 50%;
}
body {
font-family: sans-serif;
}
ul {
list-style: none
}
li {
background: slategrey;
<?php
function rkv_url_spamcheck( $approved , $commentdata ) {
$author_url = $commentdata['comment_author_url'];
$author_url_length = strlen($author_url);
if ($author_url_length > 50 )
$approved = 'spam';
@chriscoyier
chriscoyier / gist:5801571
Last active December 18, 2015 14:59 — forked from anonymous/gist:5801482
<?php
$src = '<iframe src="http://player.vimeo.com/video/68302803" width="500" height="281" frameborder="0" webkitAllowFullScreen mozallowfullscreen allowFullScreen></iframe>';
$matches = preg_match('/player\.vimeo\.com\/video\/(\d+)/', $src, $match);
if ($matches) {
$id = $match[1];
$apiurl = 'http://vimeo.com/api/v2/video/' . $id . '.json';
$response = file_get_contents($apiurl);
$json = json_decode($response, true);