Fixed markdown syntax [..]() by .. .

This commit is contained in:
2017-02-12 12:24:14 +01:00
parent 847b890b48
commit 4d4bc89129
4 changed files with 11 additions and 11 deletions

View File

@@ -94,7 +94,7 @@ Example
res.put_string (l_msg) res.put_string (l_msg)
end end
``` ```
Both features takes an INTEGER (the status code) as an formal argument, you can use 200, 300, 500 etc directly, but instead of using explicit numbers, it's recommended to use the constants defined in the class [HTTP_STATUS_CODE](). The name of each constant is based from the standard [HTTP 1.1](https://httpwg.github.io/). Both features takes an INTEGER (the status code) as an formal argument, you can use 200, 300, 500 etc directly, but instead of using explicit numbers, it's recommended to use the constants defined in the class `HTTP_STATUS_CODE`. The name of each constant is based from the standard [HTTP 1.1](https://httpwg.github.io/).
<a name="redirect"></a> <a name="redirect"></a>
@@ -124,7 +124,7 @@ The next code show a custom feature to write a redirection, you can use found or
end end
``` ```
The class [WSF_RESPONSE]() provide features to work with redirection The class `WSF_RESPONSE` provide features to work with redirection
```eiffel ```eiffel
redirect_now (a_url: READABLE_STRING_8) redirect_now (a_url: READABLE_STRING_8)
@@ -677,9 +677,9 @@ helpers
``` ```
The other way to build headers is using the class [HTTP_HEADER](), that provide routines to build a header. It's recomended to The other way to build headers is using the class `HTTP_HEADER`, that provide routines to build a header. It's recomended to
take a look at constants classes such as [HTTP_MIME_TYPES](),[HTTP_HEADER_NAMES](),[HTTP_STATUS_CODE](),[HTTP_REQUEST_METHODS](), or take a look at constants classes such as `HTTP_MIME_TYPES`,`HTTP_HEADER_NAMES`,`HTTP_STATUS_CODE`,`HTTP_REQUEST_METHODS`, or
[HTTP_CONSTANTS]() which groups them for convenience. `HTTP_CONSTANTS` which groups them for convenience.
```eiffel ```eiffel
@@ -698,7 +698,7 @@ take a look at constants classes such as [HTTP_MIME_TYPES](),[HTTP_HEADER_NAMES]
res.put_string (l_msg) res.put_string (l_msg)
end end
``` ```
The class [HTTP_HEADER]() also supplies a number of convenience routines for specifying common headers, in fact the features are inherited from the class [HTTP_HEADER_MODIFIER](). The class `HTTP_HEADER` also supplies a number of convenience routines for specifying common headers, in fact the features are inherited from the class `HTTP_HEADER_MODIFIER`.
```eiffel ```eiffel

View File

@@ -50,7 +50,7 @@ Client send cookies to server
## Write and Read Cookies. ## Write and Read Cookies.
To send a cookie to the client we should use the **HTTP_HEADER** class, and call ```h.put_cookie``` feature or To send a cookie to the client we should use the **HTTP_HEADER** class, and call ```h.put_cookie``` feature or
```h.put_cookie_with_expiration_date``` feature, see [How to set Cookies]() to learn the details, and the set it to response object **WSF_RESPONSE** as we saw previously. ```h.put_cookie_with_expiration_date``` feature, see `How to set Cookies` to learn the details, and the set it to response object **WSF_RESPONSE** as we saw previously.
We will show an example. We will show an example.

View File

@@ -35,7 +35,7 @@ Here we will show you how to read input submitted by a user using a Form (`GET`
<a name="read"></a> <a name="read"></a>
## Reading Form Data ## Reading Form Data
EWF [WSF_REQUEST]() class, provides features to handling this form parsing automatically. EWF `WSF_REQUEST` class, provides features to handling this form parsing automatically.
<a name="query"></a> <a name="query"></a>

View File

@@ -4,7 +4,7 @@ Nav: [Workbook](../workbook.md) :: [Handling Requests: Form/Query parameters](./
# Handling Requests: Headers # Handling Requests: Headers
##### Introduction ##### Introduction
- The [HTTP request header fields (also known as "headers")](https://httpwg.github.io/specs/rfc7231.html#request.header.fields) are set by the client (usually web browser) and sent in the header of the http request text (see http protocol), as opposed to form or query parameters [Form Data](). - The [HTTP request header fields (also known as "headers")](https://httpwg.github.io/specs/rfc7231.html#request.header.fields) are set by the client (usually web browser) and sent in the header of the http request text (see http protocol), as opposed to form or query parameters `Form Data`.
- Query parameters are encoded in the URL [GET requests](https://httpwg.github.io/specs/rfc7230.html#http.message). - Query parameters are encoded in the URL [GET requests](https://httpwg.github.io/specs/rfc7230.html#http.message).
- Form parameters are encoded in the request message for [POST/PUT requests.](https://httpwg.github.io/specs/rfc7230.html#http.message). - Form parameters are encoded in the request message for [POST/PUT requests.](https://httpwg.github.io/specs/rfc7230.html#http.message).
@@ -45,7 +45,7 @@ Among other, this means the header fields are exposed with associated CGI field
<a name="read_header"></a> <a name="read_header"></a>
## Reading HTTP Header fields ## Reading HTTP Header fields
EWF [WSF_REQUEST]() class provides features to access HTTP headers. EWF `WSF_REQUEST` class provides features to access HTTP headers.
Reading most headers is straightforward by calling: Reading most headers is straightforward by calling:
- the corresponding `http_*` functions such as `http_accept` for header "Accept". - the corresponding `http_*` functions such as `http_accept` for header "Accept".
@@ -113,7 +113,7 @@ This section summarizes the headers most often used; for more information, see t
* [Accept](https://httpwg.github.io/specs/rfc7231.html#header.accept) * [Accept](https://httpwg.github.io/specs/rfc7231.html#header.accept)
- The "Accept" header field can be used by user agents (browser or other clients) to define response media types that are acceptable. Accept header fields can be used to indicate that the request is limited to a small set of desired types, as in the case of a request for an inline image. - The "Accept" header field can be used by user agents (browser or other clients) to define response media types that are acceptable. Accept header fields can be used to indicate that the request is limited to a small set of desired types, as in the case of a request for an inline image.
For example, assume an APIs Learn4Kids can respond with XML or JSON data (JSON format have some advantages over XML, readability, parsing etc...), a client can define its preference using "Accept: application/json" to request data in JSON format, or "Accept: application/xml" to get XML format. In other case the server sends a not acceptable response. Note that the client can define an ordered list of accepted content types, including "*", the client will get the response and know the content type via the response header field "Content-Type". Related [Content-Negotiation]() For example, assume an APIs Learn4Kids can respond with XML or JSON data (JSON format have some advantages over XML, readability, parsing etc...), a client can define its preference using "Accept: application/json" to request data in JSON format, or "Accept: application/xml" to get XML format. In other case the server sends a not acceptable response. Note that the client can define an ordered list of accepted content types, including "*", the client will get the response and know the content type via the response header field "Content-Type". Related `Content-Negotiation`
<a name="accept_charset"></a> <a name="accept_charset"></a>