<!DOCTYPE html>
<html>
<head>
<title>Get, Post İşlemleri</title>
</head>
<body>
<?php
if(!$_GET);
{
?>
<form method="get" action="get.php">
Sayı girin: <input type="number" name="sayi">
<button type="submit">Tıkla</button>
</form>
<?php
}
else{
function hesaplama()
{
$x=$_GET['sayi'];
echo"Girilen sayı: ".$x;
}
hesaplama();
}
?>
</body>
</html>