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
from PIL import Image, ImageStat, ImageEnhance | |
from random import * | |
import numpy as np | |
from itertools import * | |
import requests | |
import simplejson | |
from cStringIO import StringIO | |
from images2gif import writeGif | |
import os, sys |
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
[SWF(width=200,height=50,backgroundColor=0x666666,frameRate=24)] | |
var sound:Sound = new Sound(); | |
/* ################ Set the Starting Frequency */ | |
var freq:Number=1046.5; | |
/* ################ Set the Sample Rate */ | |
var rate:Number=44100; | |
var phase:Number=0; | |
var chan:SoundChannel = new SoundChannel(); | |
var trans:SoundTransform = new SoundTransform(0,0); | |
chan.soundTransform = trans; |
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 currencies = { | |
'USD': '$', 'CAD': 'CA$', 'EUR': '€', 'AED': 'AED', 'AFN': 'Af', | |
'ALL': 'ALL', 'AMD': 'AMD', 'ARS': 'AR$', 'AUD': 'AU$', 'AZN': 'man.', | |
'BAM': 'KM', 'BDT': 'Tk', 'BGN': 'BGN', 'BHD': 'BD', 'BIF': 'FBu', | |
'BND': 'BN$', 'BOB': 'Bs', 'BRL': 'R$', 'BWP': 'BWP', 'BYR': 'BYR', | |
'BZD': 'BZ$', 'CDF': 'CDF', 'CHF': 'CHF', 'CLP': 'CL$', 'CNY': 'CN¥', | |
'COP': 'CO$', 'CRC': '₡', 'CVE': 'CV$', 'CZK': 'Kč', 'DJF': 'Fdj', | |
'DKK': 'Dkr', 'DOP': 'RD$', 'DZD': 'DA', 'EEK': 'Ekr', 'EGP': 'EGP', | |
'ERN': 'Nfk', 'ETB': 'Br', 'GBP': '£', 'GEL': 'GEL', 'GHS': 'GH₵', | |
'GNF': 'FG', 'GTQ': 'GTQ', 'HKD': 'HK$', 'HNL': 'HNL', 'HRK': 'kn', |
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
# Description: | |
# Anyone can have voice or op | |
# | |
# Commands: | |
# hubot make me an op | |
# hubot make <name> an op | |
# hubot give me voice | |
# hubot give <name> voice | |
module.exports = (robot) -> |
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
x$.extend({ | |
'next': function() { | |
var n = this[0]; | |
do{n = n.nextSibling;} | |
while (n && n.nodeType != 1); | |
return x$(n); | |
}, | |
'is': function(sr) { | |
sr = sr.toUpperCase(); | |
var n = this[0]; |
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
/* For modern browsers */ | |
.cf:before, | |
.cf:after { | |
content:""; | |
display:block; | |
overflow:hidden; | |
} | |
.cf:after { | |
clear:both; |
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
###################################################### | |
# Redirect to separate directory for mobile site | |
###################################################### | |
# Don't redirect if we're already there! | |
RewriteCond %{REQUEST_URI} !^/mobile/.*$ | |
# Check Cookie to (en|dis)able redirect to mobile or stay on desktop | |
RewriteCond %{HTTP_COOKIE} !^.*mobile.*$ [NC] |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>XUIaccordion Demo</title> | |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> | |
<!--[if !IE]>--> | |
<!-- no blackberry support if you use IE conditionals to detect browser, but this is a demo so relax --> | |
<script type="text/javascript" src="http://xuijs.com/downloads/xui-2.0.0.min.js"></script> | |
<!-- sorry for hotlinking, XUI dudes, but this is a demo so deal with it. --> |
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
blockquote:before { | |
content: '\201C'; | |
height: 0; | |
margin-left: -0.55em; | |
} | |
blockquote:after { | |
content: '\201D'; | |
height: 50px; | |
margin-top: -70px; | |
margin-left: 360px; |
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 | |
$agents = "/(sony|symbian|nokia|samsung|mobile|windows ce|epoc|opera mini|IEmobile|DoCoMo|nitro|j2me|midp-|cldc-|netfront|mot|up\.browser|up\.link|audiovox|blackberry|ericsson,|panasonic|philips|sanyo|sharp|sie-|ipad|ipod|iphone|portalmmm|blazer|avantgo|danger|palm|series60|palmsource|pocketpc|smartphone|rover|ipaq|au-mic,|alcatel|ericy|vodafone\/|wap1\.|wap2\.|mobile safari|android)/i"; | |
$accepts = "/(text\/vnd\.wap\.wml|application\/vnd\.wap\.xhtml\+xml)/i"; | |
if(preg_match($agents,$_SERVER['HTTP_USER_AGENT'])||preg_match($accepts,$_SERVER['HTTP_ACCEPT'])){ | |
header("Location: mobile"); | |
} | |
?> |
OlderNewer