Link to home
Start Free TrialLog in
Avatar of stevedangerfield
stevedangerfield

asked on

COM & DCOM in PHP

I was wondering what the support for COM/DCOM..
especially DCOM was for PHP..

We are going to run on a unix box/apache
and then try and talk to a remote DCOM
object (on an NT server)..

Is this possible?
Or would we have to run PHP on windows?
Or would it be best to stick with (!) ASP for this one?

Thanks,

Steve Dangerfield.
stevedangerfield@angelfire.com
Avatar of anupkarade
anupkarade

Hi
  Yess php supports com
  here is th link for you

  http://www.phpbuilder.com/manual/ref.com.php

and a small piece of code......
  paste it and enjoy...

<?
$word = new COM("word.application") or die("Unable to instanciate Word");
print "Loaded Word, version {$word->Version}\n";
$word->Visible = 1;
$word->Documents->Add();
$word->Selection->TypeText("This is a test...");
$word->Documents[1]->SaveAs("Useless test.doc");
$word->Quit();
?>          
           
                                   regards..
                                     Anup
Avatar of stevedangerfield

ASKER

thanks for that..
i previously had seen that..
but was wondering..
is this support only on windows NT version of PHP?
i guess it must be, for COM is a windows thing..
but for DCOM where the object exists
on a remote machine.. a remote NT machine..
can you use PHP (under linux) to call the remote
object?
thats the question..
ASKER CERTIFIED SOLUTION
Avatar of manucorp
manucorp

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
i think the machine you are trying to access the dcom server (the one running php) is going to need to be on windows. i beleive com is windows specific. if you are going to be doing alot of com/dcom work i would recommend sticking w/ asp on this one. asp's support for com is alot better than php since microsoft is responsible for asp and com. hope that helps.

rumblefiz
It's time to clean up this topic area and that means taking care of this question. Your options at this point are:

1. Award points to the Expert who provided an answer, or who helped you most. Do this by clicking on the "Accept Comment as Answer" button that lies above and to the right of the appropriate expert's name.

2. PAQ the question because the information might be useful to others, but was not useful to you. To use this option, you must state why the question is no longer useful to you, and the experts need to let me know if they feel that you're being unfair.

3.  Ask Community Support to help split points between participating experts.  Just comment here with details.

4.  Delete the question because it is of no value to you or to anyone else.  To use this option, you must state why the question is no longer useful to you, and the experts need to let me know if they feel that you're being unfair.

If you elect for option 2, 3 or 4, just post comment with details here and I'll take it from there.  We also request that you review any other open questions you might have and update/close them.  Display all your question history from your Member Profile to view details.

PLEASE DO NOT AWARD THE POINTS TO ME.

____________________________________________



Hi Experts:

In the event that the Asker does not respond, I would very much appreciate your opinions as to which Expert ought to receive points (if any) as a result of this question.  Likewise, you can also suggest that I PAQ or delete the question.

Experts, please do not add further "answer" information to this question.  I will be back in about one week to finalize this question.

Thank you everyone.

Moondancer :)
Community Support Moderator @ Experts Exchange

P.S.  REGARDING POINTS, Guidelines and more:  https://www.experts-exchange.com/jsp/cmtyHelpDesk.jsp