> > > What is the best way to deal with file uploads with illegal > > characters? > > I have no problem stripping the filenames such that "_Peter[1].doc" > > becomes "Peter1.doc" before it's manage_addFile'ed. > > But suppose I want to maintain the exact filename as it was on the > > harddrive, how do you deal with that? > > What is the use case? > Nothing in particular. I've been working on inbound email file attachments with weird (window$ guily) file names. http://www.issuetrackerproduct.com/News/inbound-email-feature-set-up-for-testing
> If a filename is illegal as a URL then that's that. All you could > possibly do would be to stick the illegal name into another attribute > and show it as additional piece of information for the content. You > cannot make an illegal filename legal as a URL for download, unless > you hack the regexes in CMF/Zope and just disregard interoperability. > Good point. I'm confident there's no need to do for the web then. However, there might be a solution for those who'd want to do it by using the content-disposition header from an attribute. (but that wouldn't work with wget) -- Peter Bengtsson, work www.fry-it.com home www.peterbe.com hobby www.issuetrackerproduct.com _______________________________________________ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )