On Tue, Sep 7, 2010 at 5:56 AM, Taras Puchko <[email protected]> wrote: > Hello, > > I'm trying to use a URL segment as a key for a view, like the following: > { > "from": "/tags/:tagname", > "to": "_view/by-tag", > "query": {"key": ":tagname"} > } > > The problem is that the key have to be JSON-encoded, which complicates my > API. Every client has to know how to JSON-encode strings. > > However, I have found a workaround. If I use arrays for my keys the > following works: > { > "from": "/tags/:tagname", > "to": "_view/by-tag", > "query": {"key": [":tagname"]} > } > > I'm wondering if there is a more efficient solution for this problem. > > Thanks, > Taras >
The key doesn't need to be json encoded only url encoded. If not let me know. - benoit
