PHP相當新穎。一直在嘗試一個簡單的程序從2個字段獲取數據並使用GET方法顯示它。在PHP中使用GET方法無形式數據回顯
繼承人的HTML代碼
<html>
<head>
<title>Simple Form</title>
</head>
<body>
<form action="send.php" method="get" id="sample">
Name:<input type="text" name="user"/>
Message:<input type="text" name="message"/>
<input type="submit"/>
</form>
</body>
</html>
赫雷什PHP代碼:
<html>
<body>
Welcome <?php echo $_GET["user"]; ?>
Message <?php echo $_GET["message"]; ?>
</body>
</html>
GET方法取出數據在瀏覽器的地址欄中查詢字符串,但是不顯示在瀏覽器的任何窗口。
你有什麼錯誤? – Saty
閱讀http://php.net/manual/en/function.error-reporting.php檢查頁面 – Saty
中的錯誤add error_reporting(E_ALL);在您的代碼中 –