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
curl -v POST https://api.sandbox.paypal.com/v1/payments/billing-agreements | |
-H 'Content-Type:application/json' \ | |
-H 'Authorization: Bearer {accessToken}' \ | |
-d '{ | |
"name": "Main Subscription", | |
"description": "Fruit of the Month Subscription", | |
"start_date": "2015-02-19T00:37:04Z", | |
"plan": { | |
"id": "P-0NJ10521L3680291SOAQIVTQ" | |
}, |
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
USE 'http://www.jonleblanc.com/projects/yql/weather_locations.xml' AS weather_location; select * from weather.forecast where location in (SELECT loc.id FROM weather_location WHERE location='London' LIMIT 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
<canvas id="test_canvas" width="400" height="400"> | |
If the canvas element is not supported in your browser, this text will be displayed | |
</canvas> |
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 example = document.getElementById('test_canvas'); | |
var context = example.getContext('2d'); | |
context.fillStyle = "rgb(255,0,0)"; | |
context.fillRect(30, 30, 50, 50); |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<query xmlns:yahoo="http://www.yahooapis.com/v1/base.rng" yahoo:count="10" yahoo:created="2010-03-31T06:27:19Z" yahoo:lang="en-US" yahoo:updated="2010-03-31T06:27:19Z" yahoo:uri="http://query.yahooapis.com/v1/yql?q=select+*+from+flickr.photos.search+where+has_geo%3D%22true%22+and+text%3D%22san+francisco%22"> | |
<diagnostics> | |
<publiclyCallable>true</publiclyCallable> | |
<url execution-time="444"><![CDATA[http://api.flickr.com/services/rest/?method=flickr.photos.search&has_geo=true&text=san%20francisco&page=1&per_page=10]]></url> | |
<user-time>445</user-time> | |
<service-time>444</service-time> | |
<build-version>5275</build-version> | |
</diagnostics> | |
<results> |
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 | |
$yql_url = 'http://query.yahooapis.com/v1/public/yql?'; | |
$query = 'SELECT * FROM flickr.photos.search WHERE has_geo="true" AND text="san francisco"'; | |
$query_url = $yql_url . 'q=' . urlencode($query) . '&format=xml'; | |
$photos = simplexml_load_file($query_url); | |
$result = build_photos($photos->results->photo); | |
echo $result; | |
function build_photos($photos){ |
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>Dropin</title> | |
</head> | |
<body> | |
<form id="checkout" method="post" action="http://localhost:3000/checkout"> | |
<div id="payment-form"></div> | |
<input type="submit" value="Make Payment"> |
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 express = require('express'), | |
bodyParser = require('body-parser'), | |
app = express(), | |
util = require('util'), | |
braintree = require('braintree'); | |
app.use( bodyParser.json() ); // to support JSON-encoded bodies | |
app.use(bodyParser.urlencoded({ // to support URL-encoded bodies | |
extended: true | |
})); |
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
<script type='text/javascript' src='yql_js_widget.js'></script> | |
<div id='widgetContainer'></div> | |
<script type='text/javascript'> | |
var config = {"debug":true}; | |
var format = "<br style='clear:both' /><img src='{content}' width='620' height='500' alt='map' />"; | |
var yqlQuery = "SELECT * FROM maps.map WHERE (latitude, longitude) IN (SELECT match.place.centroid.latitude, match.place.centroid.longitude FROM geo.placemaker WHERE documentURL = 'http://www.cnn.com/' AND documentType='text/html' AND appid='')"; | |
var insertEl = "widgetContainer"; |
OlderNewer