This file contains hidden or 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′?> | |
<XRD xmlns=’http://docs.oasis-open.org/ns/xri/xrd-1.0′> | |
<Subject>acct:[email protected]</Subject> | |
<Alias>http://example.com/profiles/joe</Alias> | |
<Link> | |
<Rel>http://portablecontacts.net/spec/1.0</Rel> | |
<Rel>describedby</Rel> | |
<URI>http://example.com/api/people/</URI> | |
</Link> | |
<Link> |
This file contains hidden or 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′?> | |
<XRD xmlns=’http://docs.oasis-open.org/ns/xri/xrd-1.0′> | |
<Host xmlns=’http://host-meta.net/xrd/1.0′>example.com</Host> | |
<Link> | |
<Title>Resource Descriptor</Title> | |
<Rel>describedby</Rel> | |
<URITemplate>http://example.com/api?uri={%uri}</URITemplate> | |
</Link> | |
<Link> | |
<Title>Resource Descriptor</Title> |
This file contains hidden or 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′?> | |
<XRD xmlns=’http://docs.oasis-open.org/ns/xri/xrd-1.0′> | |
<Host xmlns=’http://host-meta.net/xrd/1.0′>hosted-by-google.com</Host> | |
<Link> | |
<Title>Resource Descriptor</Title> | |
<Rel>host-meta</Rel> | |
<URITemplate>http://xrd.google.com/{%uri}</URITemplate> | |
</Link> | |
</XRD> |
This file contains hidden or 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
// Returns a single promise that emits success or error when the given promises | |
// are complete. | |
// | |
// var promises = require('promise-group') | |
// promises.group(promise1, promise2).addCallback(...) | |
// | |
exports.group = function() { | |
return new PromiseGroup(Array.prototype.slice.call(arguments)).promise; | |
} | |
This file contains hidden or 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
$args = array(); | |
$select = "SELECT i.* , f.* "; | |
$from = "FROM $FOF_FEED_TABLE f, $FOF_ITEM_TABLE i, $FOF_SUBSCRIPTION_TABLE s "; | |
$where = sprintf("WHERE s.user_id = %d AND s.feed_id = f.feed_id AND f.feed_id = i.feed_id ", $user_id); | |
if(!is_null($feed) && $feed != "") | |
{ | |
$where .= sprintf("AND f.feed_id = %d ", $feed); | |
} | |
This file contains hidden or 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
-- tables in extreme pseudocode | |
-- saved_searches: | |
int search_id primary key | |
string search | |
-- saved_searches_helper: | |
int search_id foreign key saved_searches(search_id) | |
int term_id foreign key terms(term_id) | |
int term_count |
This file contains hidden or 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
app | |
| | |
+--- latest -> checkout-2 | |
| | |
+--- checkout-1 | |
| | | |
| +--- requestHandler.js | |
| \--- lib | |
| | | |
| +--- myLib.js |
This file contains hidden or 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
// in some global context. this is just a sketch, not intended to be deployed. | |
function watchModuleUrl(url, parent) { | |
var resolvedModule = resolveModulePath(request, parent); | |
var id = resolvedModule[0], | |
paths = resolvedModule[1]; | |
findModulePath(url, paths, function (filename) { | |
if (!filename) return; |
This file contains hidden or 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 sys = require('sys'), | |
http = require('http'), | |
url = require('url'); | |
var subscriptions = {} | |
function getSubscribers (did) { | |
if (subscriptions[did]) { | |
// log open already. | |
return subscriptions[did]; |
This file contains hidden or 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
/* | |
smtpd.js is SMTP server written for node.js | |
MIT License | |
*/ | |
var tcp = require('tcp'); | |
var sys = require('sys'); |
OlderNewer