We use this "solution" with cloth wipes instead of disposable diaper wipes.
- 1 C water
- 1 T Dr. Bronner's Baby Mild Liquid Soap
- 1 T apricot oil
- 2 drops tea tree oil
var crypto = require('crypto'), | |
saltLength = 10, | |
algorithm = 'sha1'; | |
function hash(password) { | |
var salt = crypto.randomBytes(10).toString('binary'), | |
hash = crypto.createHmac(algorithm, salt).update(password).digest(); | |
return { hash: hash, salt: salt }; | |
} |
description "My awesome application daemon" | |
start on filesystem or runlevel [2345] | |
stop on shutdown | |
respawn | |
respawn limit 5 60 # Limit respawns to 5 failures in 60 seconds | |
env NODE_ENV=production | |
exec /usr/local/bin/node /path/to/application/app.js >> /path/to/application/logs/node.log 2>&1 |
var http = require('http'); | |
var app = module.exports = http.createServer(function (req, res) { | |
res.writeHead(200, {'Content-Type': 'text/html'}); | |
res.end(); | |
}); |
var cloudfiles = require('cloudfiles'), | |
request = require('request'); // Install request with `npm install request` | |
// CloudFiles client configuration | |
var configCloudFiles = { | |
auth: { | |
username: '', | |
apiKey: '', | |
host: 'auth.api.rackspacecloud.com' | |
} |
We use this "solution" with cloth wipes instead of disposable diaper wipes.
How to list the content type of all files in a Cloudfiles container.
dw-is-my-hero.js
to that folderdw-is-my-hero.js
and change USERNAME
and API_KEY
to your username and API keynode dw-is-my-hero.js CONTAINER_NAME
var myId = 10; | |
var index; | |
var item = _.detect(this._list, function(val, indx) { | |
if (val.id == myId) { | |
index = indx; | |
return true; | |
} | |
}, this); |
<?php | |
function returnArray() { | |
return array('item1', 'item2', 'item3'); | |
} | |
function array_value(&$arr, $index) { | |
return $arr[$index]; | |
} |
python -m SimpleHTTPServer | |
By default, SimpleHTTPServer serves on port 8000. To specify a port, use (where 9090 is the port you want): | |
python -m SimpleHTTPServer 9090 | |
And to run it in the background, use: | |
python -m SimpleHTTPServer & |
function generateBackground($obj) | |
{ | |
return $obj.css('background-color') + ' ' + $obj.css('background-image') + ' ' + $obj.css('background-repeat') + ' ' + $obj.css('background-attachment') + ' ' + $obj.css('background-position'); | |
} |