You are here: Re: Can ActiveX controls work in PHP running on Apache On a Windows Machine? « PHP Programming Language « IT news, forums, messages
Re: Can ActiveX controls work in PHP running on Apache On a Windows Machine?

Posted by Csaba Gabor on 11/18/14 11:43

Chung Leong wrote:
> Geoff Coope wrote:
....
> > Ultimatly I need the ActiveX object to perform some windows api functions
> > and then send the result as HTML back to the user so I cant use a Linux
> > machine but I prefer PHP and MySQL and running PHP in IIS can be
> > troublesome.
....
> It's possible but not recommended. COM support is somewhat shaky on
> PHP. You have to try it to see though. Support on PHP5 is better than
> PHP4 I believe.
>
> To load a control, you would do something like:
>
> $DelphiAxObj = new COM("TestX.TestX");
>
> Check the manual for more info:
> http://us3.php.net/manual/en/ref.com.php.

By whom is it "not recommended", and are there any concrete reasons
given beyond bad mojo? OK, I know wez (author of the PHPs COM code)
says
"com_event_sink() and com_message_pump() are intended to be used in
standalone, single-threaded processes."
but for all that, it tends to work fairly well for me in PHP5. For
vanilla COM objects, I wouldn't expect a problem.

Where you do have issues running under apache is with security.
Specifically, I mean some methods and events are locked down - in a few
instances overzealously. For example, an instance of IE started as a
COM object in PHP under Apache can be started up without issue, but
getting event notifications in that situation doesn't work. At the
same time, if your php code starts up an instance of IE by executing a
..vbs file, the IE there will be able to signal events to the vbscript
in the .vbs file just fine. How about them apples?

Csaba Gabor from Vienna

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация