[version 0.7.1 ediware**20070618050012] { hunk ./CHANGELOG.txt 1 +Version 0.7.1 +2007-06-17 +Allow streams or functions as file designators (suggested by Andrei Stebakov) + hunk ./doc/index.html 95 +
  • Potential problems hunk ./doc/index.html 641 -The current version is 0.7.0. Drakma can be installed +The current version is 0.7.1. Drakma can be installed hunk ./doc/index.html 672 +

    +A Mercurial +repository of older versions is available +at http://arcanes.fr.eu.org/~pierre/2007/02/weitz/ +thanks to Pierre Thierry. hunk ./doc/index.html 689 +

    +If you want to send patches, please read this first. hunk ./doc/index.html 788 -external-format-out. The values of the parameters alist can also be -pathnames -or lists where the first element is a pathname. These values denote -files which should be sent as part of the request body, i.e. if such -file designators are present in parameters, the -content type of the request -is always multipart/form-data. If the value -denoting a file is a list, the part of the list behind the pathname is -treated as +external-format-out. The values of +the parameters alist can also be pathnames, unary +functions, open binary input streams, or lists where the first element +is of one of the former types. These values denote files which should +be sent as part of the request body, i.e. if such file designators are +present in parameters, the content type of the +request is always multipart/form-data. If the +value denoting a file is a list, the part of the list behind the first +element is treated as hunk ./doc/index.html 860 -also explicitely provide a content-length argument +also explicitly provide a content-length argument hunk ./doc/index.html 942 -explicitely asked to close the connection after the reply has been +explicitly asked to close the connection after the reply has been hunk ./doc/index.html 1343 +
     

    Potential problems

    hunk ./doc/index.html 1345 +Some web servers (notably Paul Graham's +Arc web +server +and some +very old ones) use wrong line endings when sending the HTTP +headers. By default, Drakma won't be able to understand them, but +see Chunga's *ACCEPT-BOGUS-EOLS*. hunk ./doc/index.html 1378 -$Header: /usr/local/cvsrep/drakma/doc/index.html,v 1.65 2007/04/07 18:21:03 edi Exp $ +$Header: /usr/local/cvsrep/drakma/doc/index.html,v 1.71 2007/06/17 20:44:01 edi Exp $ hunk ./drakma.asd 2 -;;; $Header: /usr/local/cvsrep/drakma/drakma.asd,v 1.33 2007/04/07 18:21:01 edi Exp $ +;;; $Header: /usr/local/cvsrep/drakma/drakma.asd,v 1.34 2007/06/17 20:43:59 edi Exp $ hunk ./drakma.asd 37 -(defvar *drakma-version-string* "0.7.0" +(defvar *drakma-version-string* "0.7.1" hunk ./request.lisp 2 -;;; $Header: /usr/local/cvsrep/drakma/request.lisp,v 1.42 2007/04/07 18:21:01 edi Exp $ +;;; $Header: /usr/local/cvsrep/drakma/request.lisp,v 1.44 2007/06/17 20:43:59 edi Exp $ hunk ./request.lisp 73 - (when (pathnamep value) + (when (or (pathnamep value) + (streamp value) + (functionp value)) hunk ./request.lisp 84 - (let* ((pathname (first value)) - (filename (or (getf (rest value) :filename) - (file-namestring pathname))) + (let* ((file-source (first value)) + (filename (or (if (functionp file-source) "user-closure") + (if (streamp file-source) "user-stream") + (getf (rest value) :filename) + (file-namestring file-source))) hunk ./request.lisp 96 - (send-content pathname stream))) + (send-content file-source stream))) hunk ./request.lisp 199 -PARAMETERS is an alist of name/value pairs \(the car and the cdr -each being a string) which denotes the parameters which are added -to the query part of the URL or \(in the case of a POST request) -comprise the body of the request. (But see CONTENT below.) The -name/value pairs are URL-encoded using the FLEXI-STREAMS external -format EXTERNAL-FORMAT-OUT before they are sent to the server -unless FORM-DATA is true in which case the POST request body is -sent as `multipart/form-data' using EXTERNAL-FORMAT-OUT. The -values of the PARAMETERS alist can also be pathnames or lists -where the first element is a pathname. These values denote files -which should be sent as part of the request body, i.e. if files -are present in PARAMETERS, the content type of the request is -always `multipart/form-data'. If the value is a list, the part -of the list behind the pathname is treated as a plist which can -be used to specify a content type and/or a filename for the file, -i.e. such a value could look like, e.g., -\(#p\"/tmp/my_file.doc\" :content-type -\"application/msword\" :filename \"upload.doc\"). +PARAMETERS is an alist of name/value pairs \(the car and the cdr each +being a string) which denotes the parameters which are added to the +query part of the URL or \(in the case of a POST request) comprise the +body of the request. (But see CONTENT below.) The name/value pairs +are URL-encoded using the FLEXI-STREAMS external format +EXTERNAL-FORMAT-OUT before they are sent to the server unless +FORM-DATA is true in which case the POST request body is sent as +`multipart/form-data' using EXTERNAL-FORMAT-OUT. The values of the +PARAMETERS alist can also be pathnames, open binary input streams, +unary functions, or lists where the first element is of one of the +former types. These values denote files which should be sent as part +of the request body, i.e. if files are present in PARAMETERS, the +content type of the request is always `multipart/form-data'. If the +value is a list, the part of the list behind the first element is +treated as a plist which can be used to specify a content type and/or +a filename for the file, i.e. such a value could look like, e.g., +\(#p\"/tmp/my_file.doc\" :content-type \"application/msword\" +:filename \"upload.doc\"). hunk ./request.lisp 244 -also explicitely provide a CONTENT-LENGTH argument of NIL which will +also explicitly provide a CONTENT-LENGTH argument of NIL which will hunk ./request.lisp 303 -server use HTTP 1.1.) If CLOSE is T, the server is explicitely +server use HTTP 1.1.) If CLOSE is T, the server is explicitly }