[Prev][Next][Index][Thread]

Re: Need help with exporting/processing GET and POST URLs in MAC-CL-HTTP



At 5:36 PM 1996-06-14, Glenn Iba wrote:
>Greetings,
>
>  I've been trying to use GET and POST URLs in MAC-CL-HTTP and have been
>running into a number of stumbling blocks.  I'd really appreciate
>any help that anyone could offer!
>
>1. PROBLEM ONE -- GET
>
>   I have this kind of working using a :search URL, but am having
>   trouble accessing the "search-keys".  I suspect there may be a
>   bug in the search-keys parser -- it seems to be splitting at
>   #\+ characters which are encodings for space, rather than the
>   #\& characters which separate the name=value "fields".  Please
>   somebody correct me if I'm misunderstanding the syntax, as I'm
>   still a rank neophyte at HTTP protocol.

Search URLs only take + as field delimiters.

You are applying the form url-encoding scheme in the wrong place.

Access the search fields with http:search-keys applied to the url passed
into your response function.

>2. PROBLEM TWO - POST
>
>  I'm trying to handle this with a :HTTP-FORM export, and can't
>  get the export to run without error.  I couldn't find any examples
>  of plain :HTTP-FORM in the "examples:exports.lisp" file.  Only
>  examples of :HTTP-COMPUTED-FORM, which doesn't seem like what I want.

When using a regular form, you need to pass in the :pathname argument which
says where the html file containing the form is located.

See the documentation for http:export-url for more details.