Created
April 26, 2011 10:04
-
-
Save kybernetikos/942063 to your computer and use it in GitHub Desktop.
Uses https://gist.github.com/942047 to provide access to a separate couchdb running on a different port to the webserver that this file is loaded from. Assumes you've uploaded that couch-x.html file as an attachment to a document with id 'document' on 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
<html> | |
<head> | |
<title>CouchTest</title> | |
<script> | |
document.domain = window.location.hostname; | |
window.oncouchready = function(api) { | |
CouchDB = api; | |
var database = new CouchDB("somedb"); | |
// .. your code goes here.. | |
} | |
</script> | |
</head> | |
<body> | |
<iframe style='display: none' src="http://localhost:5984/webaccess/document/couch-x.html"></iframe> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment