[Zope] File Extensions in FileSystemSite Product or FileSystemDirectory View

Dieter Maurer dieter@handshake.de
Fri, 13 Jun 2003 22:42:41 +0200


Elena Schulz wrote at 2003-6-12 18:03 +0200:
 > does anybody know why and where the possible file extensions in the
 > FileSystemSite Product  or in FileSysemDirectory View (CMF) are restricted
 > to
 > [html, htm, dtml, py, gif, jpg, png] and why the fileids omit them in the
 > ZMI at least on Win?
 > 
 > I would like to extend this to zpt as it can render Pagetemplates nicely and
 > show the extensions.

I can only speak for "FileSystemDirectoryView":

  The various "FS*" modules contain registrations of the form:

     registerFileExtension(extension, FSClass)

  This specifies that files with "extension" are mapped to
  instances of "FSClass".

  Some FSClass'es discard the extension, others keep it.

  When you have a modern CMF version (1.3.1 or above),
  then you can define a "keep_extension" property with
  a true value to prevent the extension to be discarded
  for this file.


Dieter