[請益] 沒有顯示結果?
請大大們幫我看看:
在test1.htm中:
<html>
<body>
.......
<center>
<form action="response.php" method="post">
username:<input type="text" name="username"><br>
password:<input type="password" name="password"><br>
gender: male<input type="radio" name="gender"
value="male">female<input type="radio" name="gender" value="female"><br>
habit: <input type="checkbox" name="h1">打電腦 <input
type="checkbox" name="h2">聽音樂 <input type="checkbox" name="h3">看書<br>
<input type="submit" value="送出">
</form>
</center>
</body>
</html>
在response.php中:
<html>
<body>
<center>
<?php
echo "帳號:";echo $username;
echo "<br>密碼:";echo $password;
if($gender=="male"){
echo "<br>性別: 男<br>";
}
else if($gender=="female"){
echo "<br>性別: 女<br>";
}
echo "興趣: ";
if($h1=="on"){
echo "打電腦 ";
}
if($h2=="on"){
echo "聽音樂 ";
}
if($h3=="on"){
echo "看書 ";
}
echo "您已成功加入會員<br>";
?>
</center>
<a href="" rel="nofollow">http://www.yahoo.com.tw">回首頁</a>
</body>
</html>
不知道為什麼,好像變數都沒有存進去...
感謝~
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 218.164.109.64
推
07/02 20:24, , 1F
07/02 20:24, 1F
→
07/02 20:28, , 2F
07/02 20:28, 2F
→
07/02 20:29, , 3F
07/02 20:29, 3F
推
07/02 20:35, , 4F
07/02 20:35, 4F
→
07/02 20:35, , 5F
07/02 20:35, 5F
→
07/02 20:45, , 6F
07/02 20:45, 6F
推
07/02 20:53, , 7F
07/02 20:53, 7F
推
07/02 20:59, , 8F
07/02 20:59, 8F
→
07/02 21:00, , 9F
07/02 21:00, 9F
→
07/02 21:00, , 10F
07/02 21:00, 10F
推
07/02 22:02, , 11F
07/02 22:02, 11F
→
07/03 11:37, , 12F
07/03 11:37, 12F
推
07/03 11:45, , 13F
07/03 11:45, 13F
討論串 (同標題文章)
PHP 近期熱門文章
PTT數位生活區 即時熱門文章