September 2001
Intermediate to advanced
768 pages
32h 45m
English
resource new COM(string component, [string remote_server])
| component | Component to load |
| remote_server | Optional remote server for DCOM |
Creates a new instance of a COM object.
Returns:
Instance of COM object
Description:
This is technically not a function but a constructor to a reserved class called COM for accessing COM objects in PHP 4.0. This is functionally similar to com_load in PHP 3.0. From here you can easily call functions and read properties from the new COM object. For setting properties in the COM object, use com_set() and com_get(). In ASP, the code in the following example would be written as follows:
set com = Server.CreateObject("ObjectName.ClassName") Version:
Existing since version 4.0
Example:
Read now
Unlock full access