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
| // Restify Server CheatSheet. | |
| // More about the API: http://mcavage.me/node-restify/#server-api | |
| // Install restify with npm install restify | |
| // 1.1. Creating a Server. | |
| // http://mcavage.me/node-restify/#Creating-a-Server | |
| var restify = require('restify'); |
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
| xquery version "3.1"; | |
| import module namespace hc="http://expath.org/ns/http-client"; | |
| import module namespace util="http://exist-db.org/xquery/util"; | |
| import module namespace xmldb="http://exist-db.org/xquery/xmldb"; | |
| (: downloads a file from a remote HTTP server at $file-url and save it to an eXist-db $collection. | |
| : we try hard to recognize XML files and save them with the correct mimetype so that eXist-db can | |
| : efficiently index and query the files; if it doesn't appear to be XML, though, we just trust | |
| : the response headers :) |
NewerOlder