请各位再帮我看看这个脚本,多谢了

dragonconstellation 2000-05-23 05:12:00
<% @language = vbscript %>
<% option explicit
response.expires = 0
dim strfirstname,strmessage
if request.servervariables('content_length") <>0 then
' retrieving form data form post command body
strfirstname = trim(request.form("firstname"))
strmessage = trim(request.form("message"))
strmessage = replace(strmessage,vbcrlf,"<br>" &vbcrlf)
%>
<html><body>
the script has resceived the form data.<br>
first name : <% = strfirstname %><BR>
message : <% = strmessage %><br>
</body></html>
<%
else
%>
<html><body>
please provide ur name :<br>
<form action = "<% = request.servervariables("script_name") %>"
method = "post">
first name : <input type = "text" name = "firstname"><br>
ur message : <textarea name = "message">hello,
this is a text.</textarea><BR>
<input type = "submit" name = "submit" value = "submit form">
</form>
</body></html>
<% end if %>
另外,请大虾门就本例给我讲一下request
thanx again
...全文
117 5 打赏 收藏 转发到动态 举报
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
eaglet 2000-05-24
  • 打赏
  • 举报
回复
request.servervariables('content_length")
应为
request.servervariables("content_length")
改动后我在我的服务器上运行,没有问题
  • 打赏
  • 举报
回复
这不是有没有权限的问题,因为机器就是我自己的机器啊,已经在上面运行过无数的ASP程序了。应该说,还是程序问题,可惜我就找不出来
另:上述的脚本的扩展名就是ASP
hcat1999 2000-05-23
  • 打赏
  • 举报
回复
你有ASP的权限吗?
做一个最简单的页面 如将HTM文件换成ASP后缀然后上传试一试。
如果同样的错误,表示你没有ASP权限
  • 打赏
  • 举报
回复
但是为什么不能运行呢?提示HTTP 500服务器内部错误
请了
zdg 2000-05-23
  • 打赏
  • 举报
回复
request接收字符串参数...
这个例子中就是firstname, message

这个例子就是接收参数firstname, message并显示出来...

28,390

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧