Home  >  Article  >  php教程  >  PHP function that can ping port

PHP function that can ping port

大家讲道理
大家讲道理Original
2016-11-09 15:00:241209browse

'.getsoft($host,$port).'
      
    ';
            echo 'Pinging '.$host.' ['.gethostbyname($host).'] with Port:'.$port.' of data:
      
    '."\r\n";
            ob_flush();
            flush();
            for($i = 0;$i < $num;$i++)
            {
                    echo ping($host,$port);
                    ob_flush();
                    flush();
                    sleep(1);
            }
    }
?>
域名/IP: 端口:

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn