From: ········@gmail.com
Subject: POST (as opposed to GET) to a remote server from AllegroServe?
Date: 
Message-ID: <1157061666.460342.221140@i42g2000cwa.googlegroups.com>
I'm sure that this is simple, but I can't figure it out. I want to POST
to a cgi uri (non-lisp, not that that matters) from AllegroServe (or,
more generally, ACL). I know how to GET to it: e.g., (format nil
"http://uir/foo.cgi?arg1=~a&arg2=~a" arg1 arg2) ... but how do I do the
analogous thing to a server that's expecting its args from a POST
instead of from a GET?

From: ········@gmail.com
Subject: Re: POST (as opposed to GET) to a remote server from AllegroServe?
Date: 
Message-ID: <1157069539.427580.304800@p79g2000cwp.googlegroups.com>
The more specific answer is:

  (NET.ASERVE.client::do-http-request
        "http://whatever.com/cgi-bin/whatever.cgi"
        :method :post
        :query `(("key" . "value")
                      ...))

Just like GET (but for the :method)

Dh-oh!
From: Lars Rune Nøstdal
Subject: Re: POST (as opposed to GET) to a remote server from AllegroServe?
Date: 
Message-ID: <pan.2006.08.31.22.28.37.11189@gmail.com>
On Thu, 31 Aug 2006 15:01:06 -0700, JShrager wrote:

> I'm sure that this is simple, but I can't figure it out. I want to POST
> to a cgi uri (non-lisp, not that that matters) from AllegroServe (or,
> more generally, ACL). I know how to GET to it: e.g., (format nil
> "http://uir/foo.cgi?arg1=~a&arg2=~a" arg1 arg2) ... but how do I do the
> analogous thing to a server that's expecting its args from a POST
> instead of from a GET?

http://www.jmarshall.com/easy/http/#postmethod

You just remove the ? and append the rest of the `key=value'-things as a
body in the HTTP-request. Note that you must supply the `content-type' and
`content-length'-headers.

I assume you are doing this from the server/lisp-side?

-- 
Lars Rune Nøstdal
http://lars.nostdal.org/
From: ········@gmail.com
Subject: Re: POST (as opposed to GET) to a remote server from AllegroServe?
Date: 
Message-ID: <1157063472.787637.218020@e3g2000cwe.googlegroups.com>
Thanks!

> I assume you are doing this from the server/lisp-side?

Yes, that's correct.