05.05.2013 Views

Programming PHP

Programming PHP

Programming PHP

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

getmypid<br />

int getmypid( )<br />

Returns the process ID for the <strong>PHP</strong> process executing the current script. When <strong>PHP</strong> runs as<br />

a server module, any number of scripts may share the same process ID, so it is not necessarily<br />

a unique number.<br />

getprotobyname<br />

int getprotobyname(string name)<br />

Returns the protocol number associated with name in /etc/protocols.<br />

getprotobynumber<br />

string getprotobynumber(int protocol)<br />

Returns the protocol name associated with protocol in /etc/protocols.<br />

getrandmax<br />

int getrandmax( )<br />

Returns the largest value that can be returned by rand( ).<br />

getrusage<br />

array getrusage([int who])<br />

Returns an associative array of information describing the resources being used by the<br />

process running the current script. If who is specified and is equal to 1, information about<br />

the process’s children is returned. A list of the keys and descriptions of the values can be<br />

found under the getrusage(2) Unix command.<br />

getservbyname<br />

int getservbyname(string service, string protocol)<br />

Returns the port associated with service in /etc/services. protocol must be either TCP or<br />

UDP.<br />

getservbyport<br />

string getservbyport(int port, string protocol)<br />

Returns the service name associated with port and protocol in /etc/services. protocol must<br />

be either TCP or UDP.<br />

410 | Appendix A: Function Reference<br />

This is the Title of the Book, eMatter Edition<br />

Copyright © 2002 O’Reilly & Associates, Inc. All rights reserved.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!