Here is an example that works out of the box (with our simulation server):
$EasyDAClient = new COM("OPCLabs.EasyDAClient.5.0");
$ItemIds = new VARIANT(array("Simulation.Random", "Trends.Ramp (1 min)", "Trends.Sine (1 min)", "Simulation.Register_I4"));
$Results = $EasyDAClient->ReadMultipleItems("", "OPCLabs.KitServer", $ItemIds);
foreach ($Results as $X)
print $X->Vtq->ToString()."<br/>";
It produces following output (e.g.):
1.25125888851588E-03 {VARTYPE(5)} @7/28/2010 6:13:40 PM; OPCQUALITY(192)
0.667287677526474 {VARTYPE(5)} @7/28/2010 6:13:40 PM; OPCQUALITY(192)
-0.867969703914737 {VARTYPE(5)} @7/28/2010 6:13:40 PM; OPCQUALITY(192)
0 {VARTYPE(3)} @7/28/2010 6:13:40 PM; OPCQUALITY(192)
This is with QuickOPC-COM 5.01.274.1, and PHP 5.2.12. There may be no one-line way to convert the resulting VT_ARRAY back to normal PHP array, but accessing the elements, and the use of 'foreach', is possible, so you can always convert it to anything you like, in a loop. I have searched the Web a little and assembled a list of related links, just in case:
http://www.mail-archive.com/php-bugs@...
http://www.colorpilot.com/blog/com-ar...
http://bugs.php.net/bug.php?id=39596
http://www.phpwelt.net/handbuecher/cz...
http://www.nme.at/download/phpcon02_m...
http://osdir.com/ml/php-windows/2010-...
http://forums.devnetwork.net/viewtopi...
http://www.colorpilot.com/pdfcreatorp...