Delicious Bookmark this on Delicious Share on Facebook SlashdotSlashdot It! Digg! Digg



PHP : Function Reference : Network Functions : getprotobyname

getprotobyname

Get protocol number associated with protocol name (PHP 4, PHP 5)
int getprotobyname ( string name )

Example 1598. getprotobyname() example

<?php
$protocol
= 'tcp';
$get_prot = getprotobyname($protocol);
if (
$get_prot == -1) {
   echo
'Invalid Protocol';
} else {
   echo
'Protocol #' . $get_prot;
}
?>

Change Language


Follow Navioo On Twitter
checkdnsrr
closelog
debugger_off
debugger_on
define_syslog_variables
dns_check_record
dns_get_mx
dns_get_record
fsockopen
gethostbyaddr
gethostbyname
gethostbynamel
getmxrr
getprotobyname
getprotobynumber
getservbyname
getservbyport
header
headers_list
headers_sent
inet_ntop
inet_pton
ip2long
long2ip
openlog
pfsockopen
setcookie
setrawcookie
socket_get_status
socket_set_blocking
socket_set_timeout
syslog
eXTReMe Tracker