Re: No-fail `document` Function Spec
"A. Pagaltzis" <[email protected]>
| Newsgroups | gmane.text.xml.xslt.extensions |
|---|---|
| Message-ID | <20060228222625.GE9624@klangraum> |
* John L. Clark <[email protected]> [2006-02-28 22:40]: >On Tue, Feb 28, 2006 at 10:07:34PM +0100, A. Pagaltzis wrote: >> * John L. Clark <[email protected]> [1970-01-01 01:00]: >Whoa, how did this happen? -----------^^^^^^^^^^^^^^^^ >Bizarre. Anyway. That happened because I'm replying to a mail from the gzipped mbox available from the archives, which puts a datetime format in the `Date` header that mutt can’t parse. In case someone else ever needs to fix those up, the following oneliner will do the trick: perl -MHTTP::Date -pi -e's/^(Date:\s*)(.*)/"$1".time2str str2time $2/e' mboxfile >For example, I try to pull down <http://www.w3.org/Member/> >using `res:document`, and I get back an http protocol error >report with 401 in the code field. If I had access to the >`WWW-Authenticate` header information (in this case, `Basic >realm="W3C-Member"', likely shunted into a more pleasant XML >structure), what would I do with it? In case of Basic auth, I guess not much. OTOH with Digest auth, the first request always yields 401 because you need a nonce from the server before you can authenticate yourself, and that nonce comes back in the `WWW-Authenticate` header of the 401 response. Hmm, although you can’t set headers on the request anyway, and the Digest auth C-R roundtrips would be handled by the HTTP library beneath the function anyway. Err, okay. I missed most of the picture. What I was proposing would make sense to have in a more fully-featured extension for doing HTTP, not this function. Ignore me. Regards, -- Aristotle Pagaltzis // <http://plasmasturm.org/>