post.html
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, width=device-width">
<title></title>
</head>
<body>
<div>Hello world!</div>
<form action="post.php" method="post">
数据1:<input type="text" name="data1">
<br/>
数据2:<input type="text" name="data2">
<br/>
<input type="submit" name="" value="提交" placeholder="">
</form>
</body>
</html>
post.php
-***************************************************************************-
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, width=device-width">
<title></title>
</head>
<body>
<?php
// echo "nihao";
// echo PHP_VERSION;
$d1 = $_POST['data1'];
$d2 = $_POST['data2'];
echo "d1= $d1,d2=$d2";
echo "<hr/>";
print_r($_POST);
?>
</body>
</html>