当前位置:首页 > 代码 > 正文

asp在线留言源代码(asp在线留言源代码大全)

admin 发布:2022-12-19 20:47 138


本篇文章给大家谈谈asp在线留言源代码,以及asp在线留言源代码大全对应的知识点,希望对各位有所帮助,不要忘了收藏本站喔。

本文目录一览:

asp,设计一个简单的留言板,在线等

'这是添加留言的页面add.asp

'我没看见你的数据库表的名字,于是就用的lyb,你可以改,95%手打,望采纳

!--#include file="conn.asp"--

html

head

title新增留言/title

/head

body

%

if request("action") = "add" then

call add()

end if

%

form id="submitForm" name="submitForm" action="?action=add" method="post"

table id="ly" cellspacing="0" cellpadding="0" width="100%" align="center" border="0"

trd主题/tdtdinput type="text" name="zt"/td/tr

trtd内容/tdtdinput type="text" name="nr"/td/tr

trtd姓名/tdtdinput type="text" name="xm"/td/tr

trtd邮箱/tdtdinput type="text" name="yx"/td/tr

trtd/tdtdinput name="submit" type="submit" value="提交" /tr

/table

/form

%

sub add()

zt=request("zt")

nr=request("nr")

xm=request("nr")

yx=request("yx")

set rs = server.CreateObject ("adodb.recordset")

sql="select * from lyb"

rs.open sql,conn,1,3

if rs.eof and rs.bof then

rs.AddNew

rs("title")=zt

rs("body")=nr

rs("name")=xm

rs("yx")=email

rs("submit_date")=now()

rs.update

response.write("添加成功!")

else

reponse.write("添加失败!")

end if

rs.close

set rs=nothing

end sub

%

/body

/html

'这是留言查看页面带删除功能 index.asp

!--#include file="conn.asp"--

html

head

title留言板/title

/head

body

%

if request("action") = "del" then

call del()

end if

%

table id="ly" cellspacing="0" cellpadding="0" width="100%" align="center" border="0"

tr/tr

/table

form id="submitForm" name="submitForm" action="?action=del" method="post"

table id="ly" cellspacing="0" cellpadding="0" width="100%" align="center" border="0"

trtd主题/td

td内容/td

td姓名/td

td邮箱/td

td删除/td/tr

%

set rs = server.CreateObject ("adodb.recordset")

sql="select *from lyb order by submit_date desc" '这里的表名为数据库表名,排序为时间降序

rs.open sql conn 3,1

do while rs.eof=false

%

trtd%=rs("title")%/td

td%=rs("body")%/td

td%=rs("name")%/td

td%=rs("email")%/td

tda href="?action=delid=%=rs("ID")%" onClick="JavaScript:return confirm('确认删除吗?!')"删除/a/td/tr

%

rs.movenext

loop

%

/table

/form

%

sub del()

id=request("id")

set rs=conn.execute("delete from lyb where id="id)

response.write("删除成功!")

end sub

%

/body

/html

'这是数据库连接文件 conn.asp

%

set connection=Server.CreateObject("ADODB.Connection")

DBPath = Server.MapPath("Guest.mdb")

connection.Open "provider=microsoft.jet.oledb.4.0;data source="dbpath

%

求一个像这样的简单ASP留言版的源代码

留言版的整套程序!可以吗非要源代码吗?

润满企业留言版(带审核) 5.0 免费版

幻影留言版(ASP多用户版) 5.30

九狐个人留言版 3.02

下载看看!应该有你满意的!

编写一个asp留言板源代码

link href="../../css/user.css" rel="stylesheet" type="text/css"

script language="JavaScript" src="../../js/common.js"/script

script language="JavaScript" src="../../js/ubbcode.js"/script

script language="JavaScript"

function formCheck()

{

if (document.theform.nickname.value == "")

{

alert("请填写名字。");

document.theform.nickname.focus();

return false;

}

if (document.theform.content.value == "")

{

alert("请填写留言内容。");

document.theform.content.focus();

return false;

}

theform.Submit.disabled=true;

return true;

}

function showimage()

{

document.images.faceimg.src=face_image[parseInt(document.theform.face.options[document.theform.face.selectedIndex].value)];

}

body background=""

center

IFRAME marginHeight=0 marginWidth=0 noResize scrolling=no frameBorder=0 src=";bgcolor=ffffff" width=468 height=60

/IFRAME

/center

p /p

form name="theform" onsubmit="return formCheck();" method="post" action="get_post.asp"

TABLE width=550 border=0 align="center" cellPadding=0 cellSpacing=0

table width="550" border="0" align="center" cellpadding="4" cellspacing="1" bgcolor="#ebebeb"

tr

td class="pt9"

p*名字:

input name="nickname" type="text" size="15" maxlength="12" class="inputbox1"

br

Email:

input name="email" type="text" size="15" maxlength="45" class="inputbox1"

主页地址:

input name="hp_url" type="text" value="http://" size="22" maxlength="125" class="inputbox1"

/p

/td

tr

td width="409" class="pt9" !--因为图片连接的原因,本文件只适合include在script/dirname下的文件 --

img onClick=bold() src="../../images/icon_editor_bold.gif" width="23" height="22" alt="粗体" border="0"img onClick=italicize() src="../../images/icon_editor_italicize.gif" width="23" height="22" alt="斜体" border="0"img onClick=underline() src="../../images/icon_editor_underline.gif" width="23" height="22" alt="下划线" border="0"

img onClick=center() src="../../images/icon_editor_center.gif" width="23" height="22" alt="居中" border="0"img onClick=hyperlink() src="../../images/icon_editor_url.gif" width="23" height="22" alt="超级连接" border="0"img onClick=email() src="../../images/icon_editor_email.gif" width="23" height="22" alt="Email连接" border="0"img onClick=image() src="../../images/icon_editor_image.gif" width="23" height="22" alt="图片" border="0"img onClick=flash() src="../../images/icon_swf.gif" width="23" height="22" alt="Flash图片" border="0"img onClick=showcode() src="../../images/icon_editor_code.gif" width="23" height="22" alt="编号" border="0"img onClick=quote() src="../../images/icon_editor_quote.gif" width="23" height="22" alt="引用" border="0"img onClick=list() src="../../images/icon_editor_list.gif" width="23" height="22" alt="目录" border="0"

br

tr

td

table width="100%" border="0" cellpadding="0" cellspacing="0" class="pt9"

tr

td width="40" valign="top"*留言:/td

tdtextarea name="content" cols="50" rows="6" id="content"/textarea/td

/tr

/table

p align="center"

input name="replyer" type="hidden" value=""

input name="reply_content_id" type="hidden" value=""

input name="userid" type="hidden" value="79444"

input type="submit" name="Submit" value="确认留言" class="button1"

input type="reset" name="Reset" value="取消重写" class="button1"

/p/td

/tr

/table

p /p

/form

table width="550" border="0" align="center" cellpadding="2" cellspacing="1"

tr

td width="88" valign="top"

img src=""

/td

td width="417"TABLE width="100%" border=0 cellPadding=0 cellSpacing=0 class="pt9"

TBODY

TR

TD width=43 colSpan=2 height=29 rowSpan=2IMG height=29

src="../../images/1_r2_c2.gif" width=43 border=0/TD

TD background=../../images/1_r2_c4.gif height=10/TD

TD width=37 colSpan=2 height=29 rowSpan=2IMG height=29

src="../../images/1_r2_c6.gif" width=37 border=0/TD

/TR

TR

TD height=19 TABLE cellSpacing=0 cellPadding=0 width="100%" border=0

TBODY

TR

TD class="pt9" font class="filtertxt"dsfsd/font /TD

TD width="168" align=right class="pt9" /TD

/TR

/TBODY

/TABLE/TD

/TR

TR

TD width=10 background=../../images/1_r4_c2.gif/TD

TD width=27/TD

TD width="100%" height=50 img src="../../images/blank.gif" width="5" height="5"

br fdsfsdbdfssdfsdf/b br img src="../../images/blank.gif" width="5" height="5" /TD

TD width=22/TD

TD width=15 background=../../images/1_r4_c2.gif/TD

/TR

TR

TD background=../../images/1_r4_c2.gif/TD

TD/TD

TD height=1hr width="100%" size="1" noshade/TD

TD/TD

TD background=../../images/1_r4_c2.gif/TD

/TR

TR

TD width=43 colSpan=2 height=26 rowSpan=2 IMG height=26 src="../../images/1_r6_c2.gif" width=43 border=0/TD

TD align=right height=17

img src="../../images/no_home.gif" align="absmiddle" img src="../../images/no_email.gif" align="absmiddle" FONT color=#336600[2006-7-17 21:24:00]/FONT /TD

TD width=43 colSpan=2 height=26 rowSpan=2IMG height=26

src="../../images/1_r6_c6.gif" width=37 border=0/TD

/TR

TR

TD background=../../images/1_r2_c4.gif

height=9/TD

/TR

/TBODY

/TABLE/td

/tr

/table

BR

form

table width="516" border="0" cellspacing="0" cellpadding="0" align="center"

tr

td

table width=100% border=0 cellspacing=1 cellpadding=2 class=pt9trtd height=13img src=../../images/turnpage2_1.gif align=absmiddle border=0 img src=../../images/turnpage2_2.gif align=absmiddle border=0 b1/b | img src=../../images/turnpage2_3.gif align=absmiddle border=0 img src=../../images/turnpage2_4.gif align=absmiddle border=0/tdtd class=pt9 width=140 align=right共font color=red1/font页第input type=text name=JumpPage maxlength=3 size=3页input type=button value=转页 onClick="location.href='/script/user/list.asp?userid=79444page=' + this.form.JumpPage.value;"/td/tr/table

/td

/tr

/table

/form

asp在线留言源代码的介绍就聊到这里吧,感谢你花时间阅读本站内容,更多关于asp在线留言源代码大全、asp在线留言源代码的信息别忘了在本站进行查找喔。

版权说明:如非注明,本站文章均为 AH站长 原创,转载请注明出处和附带本文链接;

本文地址:http://ahzz.com.cn/post/23492.html


取消回复欢迎 发表评论:

分享到

温馨提示

下载成功了么?或者链接失效了?

联系我们反馈

立即下载