PHP network operation function Summary
This article mainly introduces the summary of PHP network operation functions. This article lists frequently used functions in networks such as gethostbyaddr, gethostbyname, header_remove, http_response_code, and ip2long. For more information, see
Checkdnsrr-performs DNS communication checks on the specified host (Domain Name) or IP address
Closelog-disable the system log Link
Define_syslog_variables-Initialize all syslog-related variables
Dns_check_record-checkdnsrr alias
Dns_get_mx-getmxrr alias
Dns_get_record-Get DNS records of the specified host
Fsockopen-open a network connection or a Unix socket connection
Gethostbyaddr-get the host name corresponding to the specified IP Address
Gethostbyname-get the IP address of the specified host name
Gethostbynamel-get a series of IP addresses corresponding to the specified host name
Gethostname-Get Host Name
Getmxrr-get the MX record corresponding to the specified host name
Getprotobyname-get the Protocol number corresponding to the specified protocol name
Getprotobynumber-obtain the protocol name corresponding to the specified Protocol Number
Getservbyname-get the port number corresponding to the specified Internet service and Protocol
Getservbyport-get the internet service corresponding to the specified protocol and port number
Header_register_callback-call a header Function
Header_remove-delete the previously set Header
Header-send a custom http packet
Headers_list-return a series of sent (or prepared) Response Header Information
Headers_sent-check whether the header has been sent or sent
Http_response_code-Get or set the HTTP response code
Inet_ntop-converts an encapsulated network address into a dot-decimal representation.
Inet_pton-converts an IP address in dotted decimal format to an encapsulated (in_addr) representation.
Ip2long-convert an IPV4 string Internet protocol to a digital format
Long2ip-convert an IPV4 digital format to a string Internet Protocol
Openlog-enable the connection of the system Logger
Pfsockopen-open a persistent network connection or Unix socket connection.
Setcookie-send cookie
Setrawcookie-send an original cookie (the cookie value is not URL encoded)
Socket_get_status-stream_get_meta_data alias
Et_set_blocking-stream_set_blocking alias
Et_set_timeout-stream_set_timeout alias
Syslog-generate a system log message