post 网页提交textarea文本框数据到php后端代码范例
网页提交textarea文本框数据到php后端代码范例 html代码 [代码片段(19行)]
html代码
<html> <head> <title>A simple HTML form from www.outofmemory.cn(脚本分享网)</title> </head> <body> <form action="form.php" method="GET"> <input type="text" name="user"> <br /> <textarea name="address" rows="5" cols="40"> </textarea> <br /> <input type="submit" value="go"> </form> </body> </html>
php后端代码,保存为form.php
<html> <head> <title>Reading textarea from form</title> </head> <body> <?php print "Welcome <b>$_POST['user']</b><p>\n\n"; print "Your address is:<p>\n\n<b>$_POST['address']</b>"; ?> </body> </html>
精彩图集
精彩文章