php实验3.1

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>GET请求</title>
</head>
<body>
<form id="form1" name="form1" method="get" action="1.php">
姓名:<input type="text" name="xm"><br>
性别:<input type="radio" name="sex" value="男">男
<input type="radio" name="sex" value="女">女<br>
<input type="submit" value="提交">
&nbsp;&nbsp;
<input type="reset" value="全部重写">
</form>
<?php
$xm=$_GET['xm'];
$sex=$_GET['sex'];
echo $xm."同学,欢迎你访问本页面"."<br>";
echo"您是一位".$sex."生!";
?>
</body>
</html>

posted @ 2022-05-09 09:42  Lindseyyip  阅读(10)  评论(0编辑  收藏  举报