# PHP COM problem

**URL:** https://forum.kirupa.com/t/php-com-problem/331930
**Category:** programming
**Created:** [November 29, 2013, 8:09pm UTC](https://forum.kirupa.com/t/php-com-problem/331930 "2013-11-29T20:09:33Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![darroosh](https://avatars.discourse-cdn.com/v4/letter/d/a88e4f/32.png) [@darroosh](https://forum.kirupa.com/u/darroosh)
#### Post date: [November 29, 2013, 8:09pm UTC](https://forum.kirupa.com/t/php-com-problem/331930/1 "2013-11-29T20:09:33Z")

</div>

Hi all ,

I’m trying to use PHP COM class , working fine with me on my local server …

But online : on my godaddy VPS ( windows server 2008 , Plesk ) , When trying to use COM , the following error appear :

> PHP Fatal error: Uncaught exception ‘com\_exception’ with message ‘Failed to create COM object `word.application’: Invalid syntax ’ in C:\Inetpub\vhosts\ajobsy.secureserver.net\httpdocs\index.php:17 Stack trace: #0 C:\Inetpub\vhosts\ajobsy.secureserver.net\httpdocs\index.php(17): com-\>com(‘word.applicatio…’) #1 {main} thrown in C:\Inetpub\vhosts\ajobsy.secureserver.net\httpdocs\index.php on line 17

Line 17 is the following:

```php
$word = new COM("word.application") or die ("Could not initialise MS Word object.");

```

Note : PHP is running as CGI application ( PHP 5.4.15 )…  
And this is copied from my PHPInfo :

> 

com\_dotnet

COM support: enabled  
DCOM support: disabled  
.Net support: enabled

What should I do ?
