incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matteo Caprari <matteo.capr...@gmail.com>
Subject Getting absolute path from a show function
Date Thu, 14 Jan 2010 14:43:41 GMT
Hi.

>From within a show function I need to know the absolute url from which
the function has been called.

The req object passed to the function is handy, but I still have two questions:

- how can I figure out the calling scheme (http or https)?
- I read the hostname from headers['x-forwared-host'] if it's present,
otherwise 'host'. Do most proxies use this header to declare the
original request?

thanks
-- 
:Matteo Caprari
matteo.caprari@gmail.com

Mime
View raw message