I'm learning couchapp and it looks pretty easy to query database items.
But I have items with attachments, and I'd like to add hyperlinks to the attachments:
<a href="/databasename/{{id}}/{{attachment}}">{{description}}</a>
I can get id
, attachment
and description
setup properly, but how do I get the current database name (or URL) from within a couchapp javascript function?