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
.spotlight { | |
background:-webkit-gradient(radial, 250 50,0,250 50,800, | |
from(rgba(255,255,255,.4)),to(transparent)) transparent; | |
background: -moz-radial-gradient(250px 50px, | |
rgba(255,255,255,.4), transparent) transparent; | |
} | |
/* | |
Found this nice little snippet on Forrst.com at http://forrst.com/posts/Add_a_spotlight_sheen_to_your_backgrounds_with-zWQ | |
*/ |
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 | |
/** | |
* Server side validation of browser id assertions | |
* | |
* @author @AlchemyCS <https://github.com/alchemycs> | |
* @see GitHub <https://gist.github.com/alchemycs> | |
* @see Mozilla Browser ID <https://browserid.org> | |
* | |
*/ |
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
destfile1.md.sample | |
destfile2.md.sample | |
destfile3.md.sample |
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
# This stops others from using simple links to your media on their site. See comments at end of GIST for limitations | |
# Prevents sites you don't own placing simple embeds on those sites. eg <img src="http://example.com/images/sample-image.png"/> | |
RewriteCond %{REQUEST_URI} ^/images/.* | |
RewriteCond %{HTTP_REFERER} !^http://(www\.)?example.com(/)?.*$ [NC] | |
RewriteRule .* - [F] | |
# Your bandwidth is precious and others shouldn't poach your bandwidth. | |
# - If someone wants to use media you have on the internet they can get it one way or another | |
# - Does not protect against spoofed headers | |
# - Doesn't stop people from right-click > download image/file (etc) |
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
/* | |
Extends the Date object to get number of seconds since UNIX epoch | |
instead of milliseconds as with .getTime() | |
*/ | |
Date.prototype.getTimestamp = function() { | |
return Math.round(this.getTime()/1000); | |
} |
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
'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) { | |
var r = Math.random()*16|0, v = c == 'x' ? r : (r&0x3|0x8); | |
return v.toString(16); | |
}); |
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
# Useful if you need a list of files in CSV or for pasting into a dictionary | |
ls |sed 's/\(.*\)/"\1",/' |
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 an SQL file that will drop all non-system databases | |
mysql -u root -p -e "show databases" | grep -v Database | grep -v mysql| grep -v information_schema| grep -v test | grep -v OLD |gawk '{print "drop database " $1 ";select sleep(0.1);"}' > drop_all_databases.sql |
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
############################################################## | |
leostick12.name=Freetronics LeoStick V1.2 | |
leostick12.upload.protocol=arduino | |
leostick12.upload.maximum_size=28672 | |
leostick12.upload.speed=1200 | |
leostick12.bootloader.low_fuses=0xde | |
leostick12.bootloader.high_fuses=0xd8 | |
leostick12.bootloader.extended_fuses=0xcb | |
leostick12.bootloader.path=diskloader | |
leostick12.bootloader.file=DiskLoader-LeoStick.hex |
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
#_______________________________________________________________________________ | |
# | |
# edam's Arduino makefile | |
#_______________________________________________________________________________ | |
# version 0.4 | |
# | |
# Copyright (C) 2011, 2012 Tim Marston <[email protected]>. | |
# | |
# Permission is hereby granted, free of charge, to any person obtaining a copy | |
# of this software and associated documentation files (the "Software"), to deal |