Пример 58-1. General usage
At first, you need to instantitiate a new System_WinDrives object. You can pass "true" as parameter to enable hard disk names, but that can crash PHP and is disabled by default. The next thing to do is checking if the class can be used. That depends on the available extensions (win32api on PHP4, and php_ffi on PHP5). If the isApiAvailable method returns true, everything is ok. Now that everything is ok, you can read the driver information via getDrivesInformation and display the output. In case the API is not available, the method tries to guess the drive list by checking if the root directories exist. |
Пред. | Начало | След. |
Introduction | Уровень выше | Constants |
HIVE: All information for read only. Please respect copyright! |