From 42dc3436d9f694241d45a8473260d495763e14c0 Mon Sep 17 00:00:00 2001 From: Jim Jagielski Date: Sat, 9 Nov 2013 14:39:01 +0000 Subject: [PATCH] xforms git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1540314 13f79535-47bb-0310-9956-ffa450edef68 --- docs/manual/developer/modguide.html.en | 39 +++++++++++-------- docs/manual/getting-started.html.en | 18 +++++---- docs/manual/mod/mod_authn_socache.html.en | 11 +++--- docs/manual/mod/mod_authn_socache.html.fr | 2 + docs/manual/mod/mod_authn_socache.xml.fr | 2 +- docs/manual/mod/mod_authn_socache.xml.meta | 2 +- docs/manual/mod/mod_env.html.fr | 4 +- docs/manual/mod/mod_headers.html.en | 7 ++-- docs/manual/mod/mod_headers.html.fr | 2 + docs/manual/mod/mod_headers.xml.fr | 2 +- docs/manual/mod/mod_headers.xml.ja | 2 +- docs/manual/mod/mod_headers.xml.ko | 2 +- docs/manual/mod/mod_headers.xml.meta | 2 +- docs/manual/mod/mod_ssl.html.fr | 2 - docs/manual/mod/quickreference.html.de | 2 +- docs/manual/mod/quickreference.html.en | 2 +- docs/manual/mod/quickreference.html.es | 2 +- docs/manual/mod/quickreference.html.ja.utf8 | 2 +- docs/manual/mod/quickreference.html.ko.euc-kr | 2 +- docs/manual/mod/quickreference.html.tr.utf8 | 2 +- docs/manual/mod/quickreference.html.zh-cn | 2 +- docs/manual/upgrading.html.fr | 2 + 22 files changed, 63 insertions(+), 50 deletions(-) diff --git a/docs/manual/developer/modguide.html.en b/docs/manual/developer/modguide.html.en index 5f3ed86a0b..b4faa66fed 100644 --- a/docs/manual/developer/modguide.html.en +++ b/docs/manual/developer/modguide.html.en @@ -1649,31 +1649,38 @@ keyValuePair* readPost(request_rec* r) { if (res != OK || !pairs) return NULL; /* Return NULL if we failed or if there are is no POST data */ kvp = apr_pcalloc(r->pool, sizeof(keyValuePair) * (pairs->nelts + 1)); while (pairs && !apr_is_empty_array(pairs)) { - i++; ap_form_pair_t *pair = (ap_form_pair_t *) apr_array_pop(pairs); apr_brigade_length(pair->value, 1, &len); size = (apr_size_t) len; buffer = apr_palloc(r->pool, size + 1); apr_brigade_flatten(pair->value, buffer, &size); buffer[len] = 0; - kvp[i]->key = apr_pstrdup(r->pool, pair->name); - kvp[i]->value = buffer; + kvp[i].key = apr_pstrdup(r->pool, pair->name); + kvp[i].value = buffer; + i++; } - return kvp; + return kvp; } -static int example_handler(request_rec *r) +static int example_handler(request_rec *r) { /*~~~~~~~~~~~~~~~~~~~~~~*/ - keyValuePair* formData; /*~~~~~~~~~~~~~~~~~~~~~~*/ formData = readPost(r); if (formData) { int i; - for (i = 0; formData[i]; i++) { - ap_rprintf(r, "%s = %s\n", formData[i]->key, formData[i]->value); + for (i = 0; &formData[i]; i++) { + if (formData[i].key && formData[i].value) { + ap_rprintf(r, "%s = %s\n", formData[i].key, formData[i].value); + } else if (formData[i].key) { + ap_rprintf(r, "%s\n", formData[i].key); + } else if (formData[i].value) { + ap_rprintf(r, "= %s\n", formData[i].value); + } else { + break; + } } } return OK; @@ -1684,13 +1691,13 @@ static int example_handler(request_rec *r) - +

Printing out every HTTP header received

- +
-static int example_handler(request_rec *r) 
+static int example_handler(request_rec *r)
 {
     /*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
     const apr_array_header_t    *fields;
@@ -1701,7 +1708,7 @@ static int example_handler(request_rec *r)
     fields = apr_table_elts(r->headers_in);
     e = (apr_table_entry_t *) fields->elts;
     for(i = 0; i < fields->nelts; i++) {
-        ap_rprintf(r, "<b>%s</b>: %s<br/>", e[i].key, e[i].val);
+        ap_rprintf(r, "%s: %s\n", e[i].key, e[i].val);
     }
     return OK;
 }
@@ -1711,9 +1718,9 @@ static int example_handler(request_rec *r)
 
 
     
-    
+
     

Reading the request body into memory

- +
@@ -1759,8 +1766,8 @@ static int example_handler(request_rec* r)
     const char  *buffer;
     /*~~~~~~~~~~~~~~~~*/
 
-    if(util_read(r, &data, &size) == OK) {
-        ap_rprintf(r, "We read a request body that was %u bytes long", size);
+    if(util_read(r, &buffer, &size) == OK) {
+        ap_rprintf(r, "We read a request body that was %" APR_OFF_T_FMT " bytes long", size);
     }
     return OK;
 }
diff --git a/docs/manual/getting-started.html.en b/docs/manual/getting-started.html.en
index e40956000b..8bc4dc0a06 100644
--- a/docs/manual/getting-started.html.en
+++ b/docs/manual/getting-started.html.en
@@ -21,7 +21,8 @@
 

Getting Started

-

Available Languages:  en 

+

Available Languages:  en  | + fr 

If you're completely new to the Apache HTTP Server, or even to running @@ -46,10 +47,10 @@ Addresses on the Web are expressed with URLs - Uniform Resource Locators www.apache.org), a URL-path (e.g. /docs/current/getting-started.html), and possibly a query string (e.g. ?arg=value) used to pass additional -arguments to the server. +arguments to the server.

-

A client (e.g., a web browser) connects to a server (e.g., your Apache HTTP Server), +

A client (e.g., a web browser) connects to a server (e.g., your Apache HTTP Server), with the specified protocol, and makes a request for a resource using the URL-path.

@@ -80,15 +81,15 @@ the servername to an IP address - the location on the Internet where the server resides. Thus, in order for your web server to be reachable, it is necessary that the servername be in DNS.

+

If you don't know how to do this, you'll need to contact your network +administrator, or Internet service provider, to perform this step for +you.

+

More than one hostname may point to the same IP address, and more than one IP address can be attached to the same physical server. Thus, you can run more than one web site on the same physical server, using a feature called virtual hosts.

-

If you don't know how to do this, you'll need to contact your network -administrator, or Internet service provider, to perform this step for -you.

-

If you are testing a server that is not Internet-accessible, you can put host names in your hosts file in order to do local resolution. For example, you might want to put a record in your hosts file to map a @@ -215,7 +216,8 @@ Here's a partial list of what you might be looking for:

-

Available Languages:  en 

+

Available Languages:  en  | + fr 

top

Comments

Notice:
This is not a Q&A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed again by our moderators if they are either implemented or considered invalid/off-topic. Questions on how to manage the Apache HTTP Server should be directed at either our IRC channel, #httpd, on Freenode, or sent to our mailing lists.