Created
February 25, 2017 17:38
-
-
Save ahmethakanbesel/9d904a8fcb7774375999a2d1f60474e4 to your computer and use it in GitHub Desktop.
PHP İnternet Hız Testi
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
for($sayi = 0; $sayi < 5; $sayi++) { | |
$kb=1024; | |
echo "aktarılıyor $kb Kb...<!-"; | |
flush(); | |
$time = explode(" ",microtime()); | |
$start = $time[0] + $time[1]; | |
for($x=0;$x<$kb;$x++){ | |
echo str_pad('', 1024, '.'); | |
flush(); | |
} | |
$time = explode(" ",microtime()); | |
$finish = $time[0] + $time[1]; | |
$deltat = $finish - $start; | |
} | |
echo "-> Test $deltat saniye sürdü. İnternet hızınız ". round($kb / $deltat, 3)."Kb/s"; | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment