A simple OLE automation using COM

NicAx64

well PHP is a powerfull text processing language designed mainly as a CGI ( common Gateway Interface ) programming language. But PHP supports rest of other features using the library extensions.
For a example you can call any win32 API call in your PHP script using the win32 API library extension.

Like this you can use COM to create COM objects ,

Oky , the code shown bellow will open a internet explore window and
navigate to a particular web site.

456 Views
About the Author

well I love technology and want to implement new and make the human life easy.ppl say I am kind thanks and I love to hear that.In programming I am not a expert , but love expertise advice , I want to listen and debug and read than code.My #1 programming language is C++. and I love VLSI and FPGA electronic subjects too.Currently I am a 3rd year student of BIT externaland I just completing my degree in informationtechnology. My favourate linux distro is slax. (there is an old story if you know RH you know RH ,if you know slax you know linux) and I love programming with the xlib and still learning it.In this semester we have a compiler theory , AI as subjects. I love those subjects. and Open,and want to think and implement something new. and my idea about the technology is Technologyshould be easily accessible , low cost , and reliable and should make the human life easy.and I living in the bambalapitiya city north colombo sri lanka.where is a best place to learn electronics. :S

<?php

// create an InternetExplorer object
$internetExplorer = new COM ( "InternetExplorer.Application") or die ("cannot create an Internet Explore Object object") ;
$internetExplorer->Visible = 1;
$internetExplorer->Navigate("http://www.bit.lk");


?>
apradhan 0 Newbie Poster

Above code giving below error

Fatal error: Class 'COM' not found in /mnt/backup/home/apradhan/public_html/test/newbe.php on line 4

can you please let me know how I get this class.

psharma 0 Newbie Poster

For getting com conection error , you have to download the pear package of OLE.and install it in your web server

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.21 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.