Hello everyone,
I want to start a ping on my IP number one, but if this first ip is timing out, I want my script to start automatiquely the check 3 other IP simultanously for comparaison.
Of course I want the result of the packet lost % to be shown for each of my IPs and that timed out time. What will be your best guest to built such a tool. I`m using PHP 4.x and MySql 4.0 and Windows XP.
What do you suggest me. »Thanks
Here is my basic PHP system script and works perfectly:
-------------------------------------------------------------------------------------------------------------
[code=php]<?php
$_ip = $_SERVER['REMOTE_ADDR'];
echo "<b>Enter the IP or the domain name of the server that you are trying to ping.</b><br>";
echo "<form method='post' action='ping.ph p?do=ping'><inp ut type='text' name='domain' class='input_lo gin' value='$_ip'>&n bsp;<input type='submit' value='Ping' class='input_lo gin'></form>";
if($_GET['do'] == 'ping')
{
$_domain = $_POST['domain'];
echo "<pre>";
//system ("tracert $_domain");
system ("ping $_domain -n 5");
echo "</pre>";
}
echo "<br>";
?>[/code]
[Please use CODE tags when posting source code. Thanks! --pbmods]
I want to start a ping on my IP number one, but if this first ip is timing out, I want my script to start automatiquely the check 3 other IP simultanously for comparaison.
Of course I want the result of the packet lost % to be shown for each of my IPs and that timed out time. What will be your best guest to built such a tool. I`m using PHP 4.x and MySql 4.0 and Windows XP.
What do you suggest me. »Thanks
Here is my basic PHP system script and works perfectly:
-------------------------------------------------------------------------------------------------------------
[code=php]<?php
$_ip = $_SERVER['REMOTE_ADDR'];
echo "<b>Enter the IP or the domain name of the server that you are trying to ping.</b><br>";
echo "<form method='post' action='ping.ph p?do=ping'><inp ut type='text' name='domain' class='input_lo gin' value='$_ip'>&n bsp;<input type='submit' value='Ping' class='input_lo gin'></form>";
if($_GET['do'] == 'ping')
{
$_domain = $_POST['domain'];
echo "<pre>";
//system ("tracert $_domain");
system ("ping $_domain -n 5");
echo "</pre>";
}
echo "<br>";
?>[/code]
[Please use CODE tags when posting source code. Thanks! --pbmods]
Comment