[Zope] creating a new file type based on content-type

Chris McDonough chris@iqgroup.com
Mon, 27 Sep 1999 21:08:53 -0400


Umm.. the message title sort of says it all.

I'd like to create a ZClass that represents a certain binary file type (in
this case, MS Project .MPP files).  I'd like to present the user with the
"File" object upload form, but once the submit button is pressed, I'd like
the file registered not as a generic "File" but as an "MS Project File"
(Zope would tell it is an MS Project file based on its content-type as sent
by the remote browser, sort of like it determines if a file is actually an
image or an HTML document now).  Files uploaded would inherit all the
management screens of the MS Project File ZClass...

Is this heavy voodoo?  (Duh, of course it is, otherwise I wouldn't be
asking)...

Can anyone give me some ideas of what to change within the Zope source to do
this?