[cvs] [Wiki] changed: MimeMagic

Jan Schneider jan at horde.org
Sat May 21 02:38:56 PDT 2005


jan  Sat, 21 May 2005 02:38:56 -0700

Modified page: http://wiki.horde.org/display.php?page=MimeMagic
New Revision:  1.2

@@ -1,16 +1,13 @@
 Although this is not how to related to horde, I am posting this here as fileinfo is quite useful and I couldnt get it working for quite some time.
 
-1. Read the /horde/doc/INSTALL
-2. pear install fileinfo-beta will not work on RHEL without the following package.
+1. Read the [http://www.horde.org/horde/docs/?f=INSTALL.html /horde/doc/INSTALL]
+2. {{pear install fileinfo-beta}} will not work on RHEL without the following package.
 3. Get the latest file package from ftp://ftp.gw.com/mirrors/pub/unix/file/
-4. Install it with ./configure --prefix=/usr && make && make install
-5. then
-
-pear install fileinfo-beta
-
-5. Add the following in php.ini
-
+4. Install it with {{./configure --prefix=/usr && make && make install}}
+5. then {{pear install fileinfo-beta}}
+6. Add the following in {{php.ini}}
+<code>
 ;Magic mime time
 mime_magic.magicfile = "/usr/share/file/magic.mime"
 
 extension=fileinfo.so
@@ -18,30 +15,24 @@
 ;;;;
 ; Note: For Red Hat Linux, packaged extension modules are now loaded via
 ; the ini files in the directory /etc/php.d.
 ;;;;
-
-so also add in /etc/php.d/fileinfo.ini
+</code>
+so also add in {{/etc/php.d/fileinfo.ini}}
+<code>
 extension=fileinfo.so
+</code>
+7. restart apache and check {{/horde/test.php}}. At this point I got MIME Magic Support: Yes
 
-6. Not sure if we need to do this, but I have done it any way. Add the following in /etc/httpd/conf/httpd.conf
-
-<IfModule mod_mime_magic.c>
-   MIMEMagicFile /usr/share/file/magic.mime
-#    MIMEMagicFile conf/magic
-</IfModule>
-
-7. restart apache and check horde/test.php. At this point I got MIME Magic Support: Yes
-
-I get the following errors in /var/log/httpd/error_log, not sure how to get rid of them and if it hampers the fileinfo functioning.
-
+I get the following errors in {{/var/log/httpd/error_log}}, not sure how to get rid of them and if it hampers the fileinfo functioning.
+<code>
 PHP Warning:  Function registration failed - duplicate name - finfo_open in Unknown on line 0
 PHP Warning:  Function registration failed - duplicate name - finfo_close in Unknown on line 0
 PHP Warning:  Function registration failed - duplicate name - finfo_set_flags in Unknown on line 0
 PHP Warning:  Function registration failed - duplicate name - finfo_file in Unknown on line 0
 PHP Warning:  Function registration failed - duplicate name - finfo_buffer in Unknown on line 0
 PHP Warning:  fileinfo:  Unable to register functions, unable to load in Unknown on line 0
 [Sat May 21 00:57:42 2005] [notice] Apache/2.0.46 (Red Hat) configured -- resuming normal operations
-
+</code>
 Request for anyone who has done the above in a proper way, do share and modify what needs to be done right.
 
 Jigish.gohil at gmail dot com


More information about the cvs mailing list