Posted by gosha bine on 05/21/07 08:47
On 21.05.2007 08:36 java.inet@gmail.com wrote:
> HI
>
>
> what is the application of resource variable
>
Resource variable is where php extensions store their data. You usually
obtain a resource from some 'init' type function and then simply pass it
around. You cannot read or inspect the content of such variable.
Pseudocode example:
$resource = extension_init_func();
extension_do_something($resource);
extension_do_something_else($resource);
etc
extension_deinit_func($resource);
Real world example:
$cc = curl_init();
curl_setopt($cc, CURLOPT_URL, "blah");
curl_exec($cc);
curl_close($cc);
--
gosha bine
extended php parser ~ http://code.google.com/p/pihipi
blok ~ http://www.tagarga.com/blok
Navigation:
[Reply to this message]
|