• λ我爱Aspx >> Asp.Net >> 怎么利用PHP去ping一个地址
  • 怎么利用PHP去ping一个地址

  • :未知  Դ:internet  :2007-5-5 19:52:18  ؼ:
  • $hname = getenv("HTTP_HOST");

    echo "<b>Your IP is:</b> <i>$ip</i><br>"

    ."<b>Trying to ping:</b> <i>$server</i><br>"

    ."<b>Using server:</b> <i>$hname</i>";

    echo "<HR noshade size=1<br>";

    echo "<b>STATS:</b><br><br>";

    $command = "ping -c4 $server";

    exec($command, $result, $rval);

    if(count($result) <= 0) {

    echo "<font color=red>没有响应</font><br>";

    echo "<HR noshade size=1>";

    exit;

    }

    for ($i = 0; $i < count($result); $i++) {

    echo "<font color=red>$result[$i]</font><br>";

    }

    echo "<HR noshade size=1>";

    #include("powered.txt");

    }

    ?>

    Ҷƪл˵?
  • һƪ英文版软件编写语言使用技巧
    һƪ利用VC++获取异构型数据库库结构信息