• 首页
  • vue
  • TypeScript
  • JavaScript
  • scss
  • css3
  • html5
  • php
  • MySQL
  • redis
  • jQuery
  • 位置: php 中文手册 -> php 内置函数

    php 网络函数

    运行时配置

    这些函数的行为受 php.ini 中的设置影响。

    网络选项配置
    名字默认可修改范围更新日志
    define_syslog_variables"0"PHP_INI_ALL在PHP5.3.0中不推荐使用。在PHP5.4.0中删除

    资源类型

    此扩展名定义返回的文件指针资源fsockopen()pfsockopen()

    预定义常量

    下列常量作为 PHP 核心的一部分总是可用的。

    openlog()
    常数描述
    LOG_CONSif there is an error while sending data to the system logger, write directly to the system console
    LOG_NDELAYopen the connection to the logger immediately
    LOG_ODELAY(default) delay opening the connection until the first message is logged
    LOG_NOWAIT
    LOG_PERRORprint log message also to standard error
    LOG_PIDinclude PID with each message
    openlog() Facilities
    常数描述
    LOG_AUTHsecurity/authorization messages (use LOG_AUTHPRIV instead in systems where that constant is defined)
    LOG_AUTHPRIVsecurity/authorization messages (private)
    LOG_CRONclock daemon (cron and at)
    LOG_DAEMONother system daemons
    LOG_KERNkernel messages
    LOG_LOCAL0 ... LOG_LOCAL7reserved for local use, these are not available in Windows
    LOG_LPRline printer subsystem
    LOG_MAILmail subsystem
    LOG_NEWSUSENET news subsystem
    LOG_SYSLOGmessages generated internally by syslogd
    LOG_USERgeneric user-level messages
    LOG_UUCPUUCP subsystem
    syslog() Priorities (in descending order)
    常数描述
    LOG_EMERGsystem is unusable
    LOG_ALERTaction must be taken immediately
    LOG_CRITcritical conditions
    LOG_ERRerror conditions
    LOG_WARNINGwarning conditions
    LOG_NOTICEnormal, but significant, condition
    LOG_INFOinformational message
    LOG_DEBUGdebug-level message
    dns_get_record() Options
    常数描述
    DNS_AIPv4 Address Resource
    DNS_CAACertification Authority Authorization Resource (available as of PHP 7.0.16 and 7.1.2)
    DNS_MXMail Exchanger Resource
    DNS_CNAMEAlias (Canonical Name) Resource
    DNS_NSAuthoritative Name Server Resource
    DNS_PTRPointer Resource
    DNS_HINFOHost Info Resource (See IANA's » Operating System Names for the meaning of these values)
    DNS_SOAStart of Authority Resource
    DNS_TXTText Resource
    DNS_ANYAny Resource Record. On most systems this returns all resource records, however it should not be counted upon for critical uses. Try DNS_ALL instead.
    DNS_AAAAIPv6 Address Resource
    DNS_ALLIteratively query the name server for each available record type.