Skip to content

Instantly share code, notes, and snippets.

http://api.yelp.com/business_review_search?num_biz_requested=1&term=wendys&location=tempe,%20az&ywsid=XXXXXXXX
example url
http://gdata.youtube.com/feeds/api/videos?q=lesueuer+car&orderby=published&start-index=11&max-results=10&v=2&prettyprint=true
for more info:
http://code.google.com/apis/youtube/2.0/developers_guide_protocol.html#Searching_for_Videos
search for flickr photos
http://api.flickr.com/services/rest/?method=flickr.photos.search&api_key=XXXXXXXX&text=LeSueur
get information after you have a photo id:
http://www.flickr.com/services/api/flickr.photos.getInfo.html
there is also this: flickr.com/photo.gne?id=185333846
class HomeController < ApplicationController
def index
consumer_key = '***'
consumer_secret = '**'
oauth = OAuth::Consumer.new(consumer_key, consumer_secret, { :site => "http://twitter.com" })
url = "http://localhost:3000/home/step_2"
request_token = oauth.get_request_token(:oauth_callback => url)
session[:token] = request_token.token
session[:secret] = request_token.secret
redirect_to request_token.authorize_url
#include <stdio.h>
//refreshing my C knowledge :)
int main(){
int a = 3;
int* p = &a;
//int v = (int) p;
printf("%lu", sizeof(p)); //64 bit?
printf("%d\n", a);
printf("%d\n", *p);
//non blocking socket server
package server3;
/**
*
*
*/
import java.io.*;
import java.nio.*;
<!doctype html>
<html>
<head>
<!--<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>-->
<script>
var words = {'function' : 0, 'var': 0, 'alert': 0, "if": 0};
load_scripts();
$().ready(function(){
@drewlesueur
drewlesueur / touch.html
Created February 28, 2010 23:20
touchmove
<!doctype html>
<html>
<head>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
<script>
$('#m')[0].touchmove = function(e){
console.log(e.tartetTouches);
}
</script>
<!doctype html>
<html>
<head>
<script>
if(!this.JSON)this.JSON={}; (function(){function k(a){return a<10?"0"+a:a}function n(a){o.lastIndex=0;return o.test(a)?'"'+a.replace(o,function(c){var d=q[c];return typeof d==="string"?d:"\\u"+("0000"+c.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+a+'"'}function l(a,c){var d,f,i=g,e,b=c[a];if(b&&typeof b==="object"&&typeof b.toJSON==="function")b=b.toJSON(a);if(typeof j==="function")b=j.call(c,a,b);switch(typeof b){case "string":return n(b);case "number":return isFinite(b)?String(b):"null";case "boolean":case "null":return String(b);case "object":if(!b)return"null"; g+=m;e=[];if(Object.prototype.toString.apply(b)==="[object Array]"){f=b.length;for(a=0;a<f;a+=1)e[a]=l(a,b)||"null";c=e.length===0?"[]":g?"[\n"+g+e.join(",\n"+g)+"\n"+i+"]":"["+e.join(",")+"]";g=i;return c}if(j&&typeof j==="object"){f=j.length;for(a=0;a<f;a+=1){d=j[a];if(typeof d==="string")if(c=l(d,b))e.push(n(d)+(g?": ":":")+c)}}else for(d in b)if(Object.hasOwnProperty.call(b,d))if(c=l(d,b))e.push(n(d)
<!doctype html>
<html>
<head>
<script>
if(!this.JSON)this.JSON={}; (function(){function k(a){return a<10?"0"+a:a}function n(a){o.lastIndex=0;return o.test(a)?'"'+a.replace(o,function(c){var d=q[c];return typeof d==="string"?d:"\\u"+("0000"+c.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+a+'"'}function l(a,c){var d,f,i=g,e,b=c[a];if(b&&typeof b==="object"&&typeof b.toJSON==="function")b=b.toJSON(a);if(typeof j==="function")b=j.call(c,a,b);switch(typeof b){case "string":return n(b);case "number":return isFinite(b)?String(b):"null";case "boolean":case "null":return String(b);case "object":if(!b)return"null"; g+=m;e=[];if(Object.prototype.toString.apply(b)==="[object Array]"){f=b.length;for(a=0;a<f;a+=1)e[a]=l(a,b)||"null";c=e.length===0?"[]":g?"[\n"+g+e.join(",\n"+g)+"\n"+i+"]":"["+e.join(",")+"]";g=i;return c}if(j&&typeof j==="object"){f=j.length;for(a=0;a<f;a+=1){d=j[a];if(typeof d==="string")if(c=l(d,b))e.push(n(d)+(g?": ":":")+c)}}else for(d in b)if(Object.hasOwnProperty.call(b,d))if(c=l(d,b))e.push(n(d)+(