中文人妻久热无码_天天看高清国产在线_富婆按摩高潮对白30分钟_国产av精选aaaaaaa

海南世紀云圖網(wǎng)絡(luò)科技有限公司
咨詢熱線:400-822-8458 客戶服務(wù):0898-32183600

Asp實例刪除Split分隔的內(nèi)容其中的某一部份

發(fā)表于:2010-12-16 00:00:00來源:人氣:3204

<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>

<%Action=Request.QueryString("Action")

Dim aID,aryTemp,Total,i,j,csID

csID=25

j=1%>

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>實例刪除Split分隔的內(nèi)容其中的某一部份</title>

<style type="text/css">

* {margin:0px; padding:0px; line-height:180%;}

a {color:#666666; text-decoration:none;}

</style>

</head>
<body>

<%

Function RtnReplaceInt(iCheck,iDefault)

 If Trim(iCheck)="" Then

  RtnReplaceInt = iDefault

  Exit Function

 End If
 If IsNumeric(iCheck)=false Then

  RtnReplaceInt = iDefault

  Exit Function

 End If
 RtnReplaceInt = iCheck

End Function
Select Case Action

Case "Add"

Call AddPic

Case "Delete"

Call DeletePic

Case else

Manage

End Select
sub Manage
end sub
sub DeletePic

uPic=Request("DelPic")

Str=Request("nPic")

Str=Replace(Str,uPic&",","")

Str=Replace(Str,","&uPic,"")

'Response.Write(""&Str&"")

'Response.End()

PicID=RtnReplaceInt(Request("PicID"),0)

sql="update 表名 set 字段='"&Str&"' where 數(shù)據(jù)庫ID in ("&Request("PicID")&")"

conn.execute(sql)

Response.write"<script>alert('操作成功!');location.href='?Action=Manage'</script>"

Response.end
end sub%>

<p>&nbsp;</p>

<table width="80%" border="0" align="center" cellspacing="0">

  <tr>

  <%aID="20101111212349940.jpg,20101111212351417.jpg,20101111212357390.jpg,20101111212402671.jpg,20101111212404837.jpg"

aryTemp = Split(aID,",")

Total=UBound(aryTemp)

for i=0 to Total

%>

    <td align="center"><a href="<%= aryTemp(i) %>"><img src="<%= aryTemp(i) %>" width="100" height="100" style="border:1px #cccccc solid;"></a><BR><a href="?Action=Delete&amp;DelPic=<%= aryTemp(i) %>&amp;PicId=<%= csID %>&amp;nPic=<%= aID %>">刪除</a></td>

 <%

j=j+1

next

%>

  </tr>

</table>
 
</body>

</html>

文章整理: 世紀云圖  http://m.jhchurchillbuilders.com/

以上信息與文章正文是不可分割的一部分,如果您要轉(zhuǎn)載本文章,請保留以上信息,謝謝!

版權(quán)申明:本站文章部份來自網(wǎng)絡(luò),如有侵權(quán),請聯(lián)系我們,我們收到后立即刪除,謝謝!

特別注意:本站部份轉(zhuǎn)載文章言論不代表本站觀點,本站所提供的攝影照片,插畫,設(shè)計作品,如需使用,請與原作者聯(lián)系,版權(quán)歸原作者所有。

微信
網(wǎng)站建設(shè)
軟件業(yè)務(wù)
網(wǎng)絡(luò)營銷
400電話