Changeset 27235 in project


Ignore:
Timestamp:
08/12/12 15:21:07 (9 years ago)
Author:
sjamaan
Message:

Document intarweb's read-urlencoded-request-data procedure

File:
1 edited

Legend:

Unmodified
Added
Removed
  • wiki/eggref/4/intarweb

    r27110 r27235  
    886886or {{transfer-coding}} header.
    887887
    888 The parameter is useful for servers to determine whether to write a
    889 response body or not.
     888The parameter is useful for servers to determine whether to read a
     889request body or not.
     890
     891<procedure>(read-urlencoded-request-data request [max-length])</procedure>
     892
     893Convenience procedure to read URLencoded request data (regular POST
     894data; ''not'' multipart data!) from the given {{request}} object.  It
     895will return an alist, as would be returned by {{form-urldecode}} from
     896the [[uri-common]] egg.
     897
     898You have to take care of checking the request type whether there
     899really will be request data yourself (it can optionally use
     900{{request-has-message-body?}} for this, but it's probably advisable to
     901check the request type anyway).
     902
     903This will read at most {{max-length}} bytes.  If not specified,
     904{{max-length}} defaults to the current value of
     905{{http-urlencoded-request-data-limit}}.
     906
     907<parameter>(http-urlencoded-request-data-limit [length])</prameter>
     908
     909Set the default limit for request body data.  Defaults to 4194304 (4MB).
    890910
    891911<parameter>(response-has-message-body-for-request? [predicate])</parameter>
     
    969989=== Changelog
    970990
    971 * trunk Treat the charset attribute for Content-Type header as case-insensitive token for consistency with Accept-Charset header.  Remove dependency on the [[/eggref/4/regex|regex egg]] and improve correctness of a few parsers.  Add {{request-has-message-body?}} and {{response-has-message-body-for-request?}} procedures.  Add parser for Content-Disposition header and improve unparser by adding date support (Thanks to Evan Hanson).  Implement line length and header count limit checking.
     991* trunk Treat the charset attribute for Content-Type header as case-insensitive token for consistency with Accept-Charset header.  Remove dependency on the [[/eggref/4/regex|regex egg]] and improve correctness of a few parsers.  Add {{request-has-message-body?}} and {{response-has-message-body-for-request?}} procedures.  Add parser for Content-Disposition header and improve unparser by adding date support (Thanks to Evan Hanson).  Implement line length and header count limit checking.  Add {{read-urlencoded-request-data}} with built-in limit check.
    972992* 0.7 Add trivial {{x-forwarded-for}} "parser".  Add easier overriding of {{authorization}} headers through parameter instead of having to rewrite the entire parser.  Add {{content-disposition}} unparser to accommodate the fact that filenames ''must'' always be quoted.  Add {{http-status-codes}} parameter and {{status:}} key to {{update-response}} and {{make-response}} procedures, as well as {{response-status}} and {{response-status-set!}} procedures.
    973993* 0.6 Change path parameters on cookies to be uri-common objects
Note: See TracChangeset for help on using the changeset viewer.