You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Eric Covener <co...@gmail.com> on 2016/01/24 18:12:43 UTC

Re: svn commit: r1726510 - in /httpd/httpd/trunk/docs/manual: expr.html.en expr.xml.meta mod/mod_cgi.html.en mod/mod_cgi.xml.fr mod/mod_cgi.xml.ja mod/mod_cgi.xml.ko mod/mod_cgi.xml.meta

On Sun, Jan 24, 2016 at 12:04 PM,  <el...@apache.org> wrote:
> @@ -115,7 +115,15 @@
>
>        <dd>This will only be set if the CGI script is subject to
>        authentication.</dd>
> +
>      </dl>
> +    <p>This module also leverages the core functions
> +       <a href="https://ci.apache.org/projects/httpd/trunk/doxygen/group__APACHE__CORE__SCRIPT.html#ga0e81f9571a8a73f5da0e89e1f46d34b1">ap_add_common_vars</a> and
> +       <a href="https://ci.apache.org/projects/httpd/trunk/doxygen/group__APACHE__CORE__SCRIPT.html#ga6b975cd7ff27a338cb8752381a4cc14f">ap_add_cgi_vars</a>
> +       to add common CGI environment variables like <code>DOCUMENT_ROOT</code>
> +       (this one from the related <code class="directive"><a href="../mod/core.html#documentroot">DocumentRoot</a></code> directive).
> +       For an exhaustive list please check the code in the appropriate httpd branch.
> +    </p>

Is this content really helpful for users? I'm not familiar with the
specific feedback this is from, but a user generally wants to know the
variables they can expect to be set and perhaps a bit of an
explanation (after all, they could run "env" as a test to see what the
varaiables are).

Re: svn commit: r1726510 - in /httpd/httpd/trunk/docs/manual: expr.html.en expr.xml.meta mod/mod_cgi.html.en mod/mod_cgi.xml.fr mod/mod_cgi.xml.ja mod/mod_cgi.xml.ko mod/mod_cgi.xml.meta

Posted by Luca Toscano <to...@gmail.com>.
Hi Eric,

2016-01-24 18:12 GMT+01:00 Eric Covener <co...@gmail.com>:
>
>
> Is this content really helpful for users? I'm not familiar with the
> specific feedback this is from, but a user generally wants to know the
> variables they can expect to be set and perhaps a bit of an
> explanation (after all, they could run "env" as a test to see what the
> varaiables are).
>

a bit of context:
- https://bz.apache.org/bugzilla/show_bug.cgi?id=58305
- https://bz.apache.org/bugzilla/show_bug.cgi?id=58306

The user asked the following things (in the context of httpd and CGI
scripts):
- Is the env var DOCUMENT_ROOT passed by httpd to CGI?
- What are the httpd Directives (like DocumentRoot) that have the
consequence of setting/passing an environment variable to the CGI script?

This commit answers the first question and adds context for the people that
might need a quick "where to look" reference for the second one. The long
term plan is for me to study those functions and add a precise list of
variables in the mod_cgi's page (but it will requires a bit of time).

Having some precise information to clarify some doubts can bring value to
the documentation in my opinion, but I agree with you that I can do a more
precise work (as stated above). Dumping the environment variables from the
CGI script can be an option, but the result might vary with the Apache
directives set, so at least a reference in the docs that this might happen
can help in my opinion.

So this is the long story, if I didn't convince you I'll revert the commit
asap and I'll work on something better :)

Let me know!

Luca