| Question : | How to access a COM object from within my PHP page? | |
| | Answer : | PHP4 doesn't use the "com_load" function anymore.
I got my example from the user-contributed notes off this page...
http://www.php.net/manual/ref.com.php
<?
$word=new COM("word.application") or die("Cannot start word for you");
print "Loaded word version ($word->Version)\n";
$word->visible =1;
$word->Documents->Add();
$word->Selection->Typetext("Dit is een test");
$word->Documents[1]->SaveAs("burb ofzo.doc");
$word->Quit();
?>
| | |