load external resources (e.g. jqm) from the couch to prevent cross domain security problems; fixes #1