简体   繁体   中英

PHP Fatal error: Class 'COM' not found (Already added entry into PHP.ini)

Using Windows Server 2008 R2 which is running IIS which has PHP 5.3.28 installed.

Everytime I try and run my application I get PHP Fatal error: Class 'COM' not found however I have added the entry to the .ini file.

Can't get it to work any ideas?

PHP Info:

   System  Windows NT CPLAS11 6.1 build 7601 (Windows Server 2008 R2 Standard Edition Service Pack 1) i586  
    Build Date  Dec 10 2013 22:04:40  
    Compiler  MSVC9 (Visual C++ 2008)  
    Architecture  x86  
    Configure Command  cscript /nologo configure.js "--enable-snapshot-build" "--enable-debug-pack" "--disable-zts" "--disable-isapi" "--disable-nsapi" "--without-mssql" "--without-pdo-mssql" "--without-pi3web" "--with-pdo-oci=C:\php-sdk\oracle\instantclient10\sdk,shared" "--with-oci8=C:\php-sdk\oracle\instantclient10\sdk,shared" "--with-oci8-11g=C:\php-sdk\oracle\instantclient11\sdk,shared" "--with-enchant=shared" "--enable-object-out-dir=../obj/" "--enable-com-dotnet=shared" "--with-mcrypt=static" "--disable-static-analyze"  
    Server API  CGI/FastCGI  
    Virtual Directory Support  disabled  
    Configuration File (php.ini) Path  C:\Windows  
    Loaded Configuration File  C:\Program Files (x86)\PHP\php.ini  
    Scan this dir for additional .ini files  (none)  
    Additional .ini files parsed  (none)  
    PHP API  20090626  
    PHP Extension  20090626  
    Zend Extension  220090626  
    Zend Extension Build  API220090626,NTS,VC9  
    PHP Extension Build  API20090626,NTS,VC9  
    Debug Build  no  
    Thread Safety  disabled  
    Zend Memory Manager  enabled  
    Zend Multibyte Support  disabled  
    IPv6 Support  enabled  
    Registered PHP Streams  php, file, glob, data, http, ftp, zip, compress.zlib, compress.bzip2, https, ftps, phar  
    Registered Stream Socket Transports  tcp, udp, ssl, sslv3, sslv2, tls  
    Registered Stream Filters  convert.iconv.*, mcrypt.*, mdecrypt.*, string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*, consumed, dechunk, zlib.*, bzip2.*  

In the installation documentaion for COM class - http://www.php.net/manual/en/com.installation.php - it indicates the with teh version of PHP you are using you must enable php_com_dotnet.dll in php.ini.

Make sure you have an entry like this in your php.ini

[COM_DOT_NET]
extension=php_com_dotnet.dll 

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM