Perhaps this has been covered before. If yes, just direct me to the link.

It there a plan to support MS Office 2007 doc formats - docx, pptx, xlsx etc.?

Tried docx format, and it worked - converted and indexed without a specific helper function declared though, like docx catFromDoc. But it didn't work work pptx extension.

Also, how do I enable the image(s) for the the Office 2007 format?

thanks!

Comments

krashid’s picture

Managed to get this working.

Added mime-types for pptx, docx and xlsx according in function mimecheck() and subsequently associated the mime-types with the icon in function dbfm_get_icon().

Seems to be working now. Able to convert, index and search the files accordingly.
Summary of changes in function mimecheck()

 case "xlsx":
          $filemime = "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";
          break;  
 case "docx":
          $filemime = "application/vnd.openxmlformats-officedocument.wordprocessingml.document";
          break;
case "pptx":
          $filemime = "application/vnd.openxmlformats-officedocument.presentationml.presentation";
          break;

Summary of changes in function dbfm_get_icon()

case 'application/vnd.openxmlformats-officedocument.presentationml.presentation':
      $icon = 'powerpoint';
      break;  
case 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet':
      $icon = 'excel';
      break;  
case 'application/vnd.openxmlformats-officedocument.wordprocessingml.document':
      $icon = 'word';
      break; 
geoff_eagles’s picture

I'm surprised that it's converting and indexing the files. What conversion function did you assign to those file types?

The new Microsoft filetypes are zipped XML files. I couldn't find any open source application that would readily convert them so I tried automatically opening them with OpenOffice then saving them as a different filetype. It worked but wasn't straightforward (or particularly fast) and didn't work with powerpoint. If you like I can send details of how I did it - but not for a week or so because I'm struggling to get a release ready just now.

krashid’s picture

I just added entry in the helper function of the dbfm search admin page referring to the same function as the one used for doc, etc. My catdoc version is 0.94.2.