couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nikolai Teofilov <n.teofi...@gmail.com>
Subject Re: Shows with request query strings
Date Sat, 27 Mar 2010 22:53:20 GMT
Thanks Ladislav!
:)

On 27.03.2010, at 23:45, Ladislav Thon wrote:

>> 
>> function(doc, req) {
>> return {
>>   body : doc._id + " " + req.test
>> }
>> }
>> 
> 
> IIRC, query parameters are in req.query, that is req.query.test in your
> case.
> 
> LT
> 
> 
>> then calling the function on a document with query string:
>> 
>> http://127.0.0.1:5984/test/_design/app/_show/test/dummy?test=ok
>> 
>> I  expect to get:
>> 
>> dummy ok
>> 
>> but the result is:
>> 
>> 
>> dummy undefined
>> 
>> Is it possible to use both arguments in a show function?
>> 
>> I need to format an attachment from specified document.
>> 
>> Currently I try this with 0.11.0b922675 under OS X 10.62
>> 
>> Cheers
>> Nikolai
>> 
>> 
>> 
>> 


Mime
View raw message