[version 0.15.3 ediware**20080317180018] { hunk ./CHANGELOG 1 +Version 0.15.3 +2008-03-17 +Added CODE parameter to REDIRECT (thanks to Michael Weber) + hunk ./doc/index.html 151 -current version is 0.15.2. +current version is 0.15.3. hunk ./doc/index.html 345 +
permanently
-is true (the default is NIL
), a 301 status
-code will be sent, otherwise a 302 status code. If host
+If code
is a 3xx redirection code, it will be sent
+as status code. In case of NIL
, a 302 status code
+will be sent to the client.
+If host
hunk ./doc/index.html 2629
-$Header: /usr/local/cvsrep/hunchentoot/doc/index.html,v 1.137 2008/03/06 07:46:52 edi Exp $
+$Header: /usr/local/cvsrep/hunchentoot/doc/index.html,v 1.138 2008/03/17 11:40:26 edi Exp $
hunk ./hunchentoot.asd 2
-;;; $Header: /usr/local/cvsrep/hunchentoot/hunchentoot.asd,v 1.57 2008/03/06 07:46:50 edi Exp $
+;;; $Header: /usr/local/cvsrep/hunchentoot/hunchentoot.asd,v 1.58 2008/03/17 11:40:25 edi Exp $
hunk ./hunchentoot.asd 37
-(defvar *hunchentoot-version* "0.15.2"
+(defvar *hunchentoot-version* "0.15.3"
hunk ./misc.lisp 2
-;;; $Header: /usr/local/cvsrep/hunchentoot/misc.lisp,v 1.16 2008/02/28 23:06:58 edi Exp $
+;;; $Header: /usr/local/cvsrep/hunchentoot/misc.lisp,v 1.17 2008/03/17 11:40:25 edi Exp $
hunk ./misc.lisp 237
- permanently)
+ code)
hunk ./misc.lisp 243
-Adds a session ID if ADD-SESSION-ID is true. If PERMANENTLY is true,
-a 301 request is sent to the browser, otherwise a 302."
+Adds a session ID if ADD-SESSION-ID is true. If CODE is a 3xx
+redirection code, it will be sent as status code. In case of NIL, a
+302 status code will be sent to the client."
+ (setf code (or code +http-moved-temporarily+))
+ (check-type code (integer 300 399))
hunk ./misc.lisp 260
- (setf (header-out :location)
- url
- (return-code *reply*)
- (if permanently
- +http-moved-permanently+
- +http-moved-temporarily+))
+ (setf (header-out :location) url
+ (return-code *reply*) code)
}