<!DOCTYPE >
<html lang="en"> <head> <meta charset="UTF-8"> <title>Website Speed Checker</title> </head> <body> <h1>Website Speed Checker</h1> <form action="" method="POST"> <input type="text" name="url" placeholder="Enter website URL"> <input type="submit" value="Check Speed"> </form> <?php if ($_POST) { // Get the website URL $url = $_POST['url']; // Check the website speed $response = file_get_contents($url); $time = microtime(true) - $_SERVER['REQUEST_TIME_FLOAT']; // Display the results echo "<h2>Results</h2>"; echo "<p>Page load time: " . $time . " seconds</p>"; echo "<p>Response size: " . strlen($response) . " bytes</p>"; } ?> </body> </html>