[Zope] mozilla multipart/form-data

Bryan C. Andregg bryan.andregg@duke.edu
Thu, 14 Mar 2002 16:52:39 -0500


--7uidztUHYC105IRM
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Recent versions of mozilla appear to change how multipart/form-data is hand=
led
by the client when an input type=3Dfile is used.

mozilla-0.9.2.1 and the two versions of netscape that I've tried apparently
send all form data such that empty file fields are still seen as file objec=
ts
to Zope.

mozilla-0.9.9 sends data such that empty file fields are empty strings (such
as a regular input type=3Dtext).

This of course breaks Zope products that check file field uploads by using =
the
_.len(request['file']).read() method. They'll need to be wrapped in an if
statement now, I guess.

Has anyone else seen this?

I've talked to some mozilla people and their take is that mozilla was and
still is doing the right thing.
--=20
Bryan C. Andregg		Duke University Medical Center
 Programmer			Dept. of Anesthesiology
 e <bryan.andregg@duke.edu>
 p +1 919 684 6201

--7uidztUHYC105IRM
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE8kRunj9pElyS/cakRAp5qAJ9Cj7mL8cX1dbHrzhjfudvz7U0JnACfQcrU
ZDmIP+rLNhVBotQBxykIb8o=
=ICle
-----END PGP SIGNATURE-----

--7uidztUHYC105IRM--