[cvs] commit: framework/MIME/MIME Magic.php

Jan Schneider jan at horde.org
Fri Mar 26 09:56:58 PST 2004


jan         2004/03/26 09:56:58 PST

  Modified files:
    MIME/MIME            Magic.php 
  Log:
  Add analyzeData() method. Like analyzeFile() but takes a string.
  As we step in extToMIME() now through all possible extension parts (from the
  longest to the shortest), we don't need to step in filenameToMIME()
  too. Instead we search there for the longest possible extension (based on
  __MAXPERIOD__) and pass that to extToMIME(). This fixes files without
  extensions not being detected as text/plain, e.g. in Chora where you couldn't
  view files like README anymore.
  
  Revision  Changes    Path
  1.46      +38 -8     framework/MIME/MIME/Magic.php

  Chora Links:
  http://cvs.horde.org/diff.php/framework/MIME/MIME/Magic.php?r1=1.45&r2=1.46&ty=u


More information about the cvs mailing list