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 strict'; | |
var Reflux = require('reflux'); | |
var axios = require('axios'); | |
var Actions = Reflux.createActions({ | |
load: { | |
children: ['completed', 'failed'] | |
} | |
}); |
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
{ | |
"name": "my-app", | |
"version": "1.0.0", | |
"description": "My test app", | |
"main": "src/js/index.js", | |
"scripts": { | |
"jshint:dist": "jshint src/js/*.js", | |
"jshint": "npm run jshint:dist", | |
"jscs": "jscs src/*.js", | |
"browserify": "browserify -s Validating -o ./dist/js/build.js ./lib/index.js", |
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
function upload(name, file, callback) { | |
Ti.include('lib/sha-aws.js'); // file comes from this URL's project: http://aws.amazon.com/code/Amazon-S3/3236824658053653 | |
Ti.include('lib/webtoolkit.utf8.js'); // code for this file from this URL: http://www.webtoolkit.info/javascript-utf8.html | |
Ti.include('lib/date.js'); // file comes from this URL: http://www.mattkruse.com/javascript/date/source.html | |
var AWSAccessKeyID = appGlobal.config.s3AccessKey; | |
var AWSSecretAccessKey = appGlobal.config.s3SecretKey; | |
var AWSBucketName = appGlobal.config.s3BucketName; | |
var AWSHost = appGlobal.config.s3Host; |
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 parser = document.createElement('a'); | |
parser.href = "http://example.com:3000/pathname/?search=test#hash"; | |
parser.protocol; // => "http:" | |
parser.hostname; // => "example.com" | |
parser.port; // => "3000" | |
parser.pathname; // => "/pathname/" | |
parser.search; // => "?search=test" | |
parser.hash; // => "#hash" | |
parser.host; // => "example.com:3000" |
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 | |
/** | |
* Super-simple AWS CloudFront Invalidation Script | |
* | |
* Steps: | |
* 1. Set your AWS access_key | |
* 2. Set your AWS secret_key | |
* 3. Set your CloudFront Distribution ID | |
* 4. Define the batch of paths to invalidate | |
* 5. Run it on the command-line with: php cf-invalidate.php |
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
/** | |
* | |
* | |
* Copyright 2011 Aaron K. Saunders, Clearly Innovative Inc | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a> |
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 | |
/** | |
* A simple Facebook PHP example. | |
* | |
* - This is not a "Facebook SDK". | |
* - This example uses Curl, Hash, JSON, Session extensions. | |
* - This does not use the JavaScript SDK, nor the cookie set by it. | |
* - This works with Canvas, Page Tabs with IFrames, the Registration Plugin | |
* and with any other flow which uses the signed_request. |