Re: php_w32api.dll ... fatal error

From: Date: Tue, 21 Oct 2003 11:44:36 +0000
Subject: Re: php_w32api.dll ... fatal error
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-166942@lists.php.net to get a copy of this message
One of the notes tells you about how to use it... It is somewhat changed from what the documentation says... $api = new win32; $api->definetype("MEMORYSTATUS { long dwLength; long dwMemoryLoad; long dwTotalPhys; long dwAvailPhys; long dwTotalPageFile; long dwAvailPageFile; long dwTotalVirtual; long dwAvailVirtual; }"); $api->registerfunction("long GlobalMemoryStatus (MEMORYSTATUS &a) From kernel32.dll"); $api->registerfunction("long memstat_phys (long &a1,long &a2) From w32apitest.dll"); $api->registerfunction("long memstat_pf (long &a1,long &a2) From w32apitest.dll"); $api->registerfunction("long cool (MEMORYSTATUS a1) From w32apitest.dll"); $a=$api->InitType("MEMORYSTATUS"); $api->GlobalMemoryStatus($a); // call a w32api function -- // DvDmanDT MSN: dvdmandt@hotmail.com Mail: dvdmandt@telia.com "Jon" <jzuazoa@euskalnet.net> skrev i meddelandet news:20031021074722.80440.qmail@pb1.pair.com... > When trying to run the following script, it returns the following error > "...Fatal error: Call to undefined function: w32api_register_function()...". > Does this w32api extension work? > > // Define constants needed, taken from > // Visual Studio/Tools/Winapi/WIN32API.txt > define("MB_OK", 0); > > // Load the extension in > dl("php_w32api.dll"); > > // Register the GetTickCount function from kernel32.dll > w32api_register_function("kernel32.dll", > "GetTickCount", > "long");

« previous php.general (#166942) next »