connection_status
Return to the status bit of the connection
connection_status() function returns the current connection status.
Possible values that can be returned:
Return to the connection status:
<?php
switch ( connection_status ( ) )
{
case CONNECTION_NORMAL :
$txt = 'Connection status is normal' ;
break ;
case CONNECTION_ABORTED :
$txt = 'Connection aborted' ;
break ;
case CONNECTION_TIMEOUT :
$txt = 'Connection timeout' ;
break ;
case ( CONNECTION_ABORTED & CONNECTION_TIMEOUT ) :
$txt = 'Connection aborted and timed out' ;
break ;
default :
$txt = 'Unknown' ;
break ;
}
echo $txt ;
?>
Try it yourself
connection_status ( )