Replicate data from CouchDB to PouchDB for offline storage on windows 7 using google Chrome V22-open source projects pouchdb/pouchdb
I am trying to replicate data from CouchDB to PouchDB for offline storage using the code to pull data from CouchDB:
db.replicate.from('http://test.iriscouch.com/todo','idb://todo', function (err, changes) {
if (err) {
console.log(err);
}
else {
console.log(changes);
}});
$scope.loadTodos(response.rows);
I get these errors:
- Failed to load resource: the server responded with a status of 405 (Method Not Allowed)
- XMLHttpRequest cannot load http://test.iriscouch.com/todo/. Origin null is not allowed by Access-Control-Allow-Origin.
- Uncaught TypeError: Cannot call method ‘id’ of undefined
Is there something I’m not doing correct?