博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
asp企业网站源码部分
阅读量:6320 次
发布时间:2019-06-22

本文共 6899 字,大约阅读时间需要 22 分钟。

ASP的网页文件的格式是.asp,现在常用于各种动态网站中。

PHP是一种 HTML 内嵌式的语言,PHP与微软的ASP颇有几分相似,都是一种在服务器端执行的嵌入HTML文档的脚本语言,语言的风格有类似于C语言,现在被很多的网站编程人员广泛的运用。

1 
2
3
4
5
6 7 8
9
10
11
12
13 <%=WebName%>-关于我们 14 <% 15 Dim id 16 Id =Request.QueryString("Id") 17 If Id ="" Or Not IsNumeric(Id) Or IsNull(Id) Then 18 Id = 2 19 End If 20 Function webTitle(Id) 21 Select Case Id 22 Case 2 webTitle = "gsjj.png" 23 Case 5 webTitle = "zzry.png" 24 Case 6 webTitle = "zzjg.png" 25 Case Else webTitle = "gsjj.png" 26 End Select 27 End Function 28 %> 29 30 31 32
33 34
35
36
37
38
39
40
54
55
56
57
58
59
235
236
41
42
43
52
53
 
60
61
184
233
234
62
63
72
73
74
75
76
77
78
79
80
179
180
181
182
183
 
81
82
83
176
177
84
85
86
87
88
89
170
171
172
173
174
175
 
  90
91
92
167
168
93 <% 94 If Id = 5 Then 95 Set Rs=server.CreateObject("adodb.recordset") 96 Sql="select title,About,id,Sm_img,Addtime from Content where BoardId="&id&" and Isdel = 0 order by IsTop Desc,IfGood Desc,Addtime Desc" 97 Rs.Open Sql,Conn,1,1 98 If Rs.Eof Then 99 Response.Write("没有信息")100 Else101 Rs.PageSize =20 102 pre = true103 last = true104 page = trim(Request.QueryString("page"))105 106 If len(page) = 0 then107 intpage = 1108 pre = false109 else110 If cint(page) =< 1 then111 intpage = 1112 pre = false113 else114 If cint(page) >= rs.PageCount then115 intpage = rs.PageCount116 last = false117 else118 intpage = cint(page)119 end If120 end If121 end If122 If not rs.eof then123 rs.AbsolutePage = intpage124 end If 125 for i=1 to rs.PageSize126 If rs.EOF or rs.BOF then exit for127 %>128
129
130
135
148
149
150
151
152
153
131 " target="_blank">132 " width="170" height="110" border="0">133 134
136
137
140
141
142
145
146
138 <%=Rs("title")%> [ <%=FormatDate(Rs("Addtime"),2)%> ]139
143 <%=Rs("About")%>144
147
   
154 <%155 Rs.movenext156 Next 157 End If158 %>159 <%160 Call showpage("?id="&id&"&")161 Set Rs=Nothing162 Else163 Echo(OneMsg(Id))164 End If165 %>166
169
 
 
178
 
185
186
231
232
187
188
205
206
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
 
 
207
208
209
210
211
212
213
214
219
220
215
216
217
218
221
222
223
224
225
226
227
228
229
230
<%=OneMsg(23)%>
237
238
239
240
241
242 243 244
View Code
1 
2
3
4
5 <% 6 Dim BoardId,Id,BoardName,style,Action,Classification 7 Dim Title,About,Content,AddMan,MyPx,IfGood,IsTop,Pic,nfrom,PicNews,Sm_Img,IsColse,Big_Img,Att,AddTime,Http,Articlekey 8 9 BoardId = Request("BoardId") 10 Id = Request("Id") 11 BoardName = Trim(Request("BoardName")) 12 style = Request.QueryString("style") 13 Action = Request.Form("Action") 14 Title = Trim(Request.Form("Title")) 15 Content = Request.Form("Content") 16 About = Request.Form("About") 17 AddMan = Request.Form("AddMan") 18 Articlekey = Request.Form("Articlekey") 19 MyPx = Request.Form("MyPx") 20 IfGood = Request.Form("IfGood") 21 IsTop = Request.Form("IsTop") 22 Pic = Request.Form("Pic") 23 web_url = Request.Form("web_url") 24 Http = Request.Form("Http") 25 nfrom = Request.Form("nfrom") 26 PicNews = Request.Form("PicNews") 27 IsColse = Request.Form("IsColse") 28 Sm_img = Request.Form("Sm_img") 29 Big_Img = Request.Form("Big_Img") 30 Att = Request.Form("Att") 31 AddTime = Request.Form("AddTime") 32 Classification = Request.Form("Classification") 33 If MyPx="" Then 34 MyPx=0 35 End If 36 If IsColse="" Then 37 IsColse=0 38 End If 39 If PicNews="" Then 40 PicNews=0 41 End If 42 If IsTop="" Then 43 IsTop=0 44 End If 45 If IfGood="" Then 46 IfGood=0 47 End If 48 If Classification = "" Then 49 Classification = 0 50 End If 51 Sub Do_Add(DoId) 52 Set Rs=server.CreateObject("adodb.recordset") 53 Sql="select * from Content" 54 Rs.Open Sql,Conn,1,3 55 Rs.addnew 56 Rs("BoardId") = BoardId 57 Rs("Title") = Title 58 Rs("About") = About 59 Rs("Content") = Content 60 Rs("Articlekey") = Articlekey 61 Rs("MyPx") = MyPx 62 Rs("IfGood") = IfGood 63 Rs("IsTop") = IsTop 64 Rs("Pic") = Pic 65 Rs("nfrom") = nfrom 66 Rs("PicNews") = PicNews 67 Rs("Sm_Img") = Sm_Img 68 Rs("IsColse") = IsColse 69 Rs("Big_Img") = Big_Img 70 Rs("web_url") = web_url 71 Rs("Http") = Http 72 Rs("Att") = Att 73 Rs("Classification") = Classification 74 Rs("AddTime") = now() 75 Rs.Update 76 Call Show_Msg("信息添加成功!","Public_List.asp?Boardid="&Boardid&"&Boardname="&Boardname) 77 Rs.Close 78 Set Rs=Nothing 79 End Sub 80 81 Sub Do_Edit(DoId) 82 83 Set Rs=server.CreateObject("adodb.recordset") 84 Sql="select * from Content where Id= "&DoId 85 Rs.Open Sql,Conn,1,3 86 Rs("BoardId") = BoardId 87 Rs("Title") = Title 88 Rs("About") = About 89 Rs("Content") = Content 90 Rs("AddMan") = AddMan 91 Rs("Articlekey") = Articlekey 92 Rs("MyPx") = MyPx 93 Rs("IfGood") = IfGood 94 Rs("IsTop") = IsTop 95 Rs("Pic") = Pic 96 Rs("nfrom") = nfrom 97 Rs("PicNews") = PicNews 98 Rs("Sm_Img") = Sm_Img 99 Rs("IsColse") = IsColse100 Rs("Big_Img") = Big_Img101 Rs("web_url") = web_url102 Rs("Http") = Http103 Rs("Att") = Att104 Rs("AddTime") = AddTime105 Rs("Classification") = Classification106 Rs.Update107 Call Show_Msg("信息修改成功!","Public_List.asp?Boardid="&Boardid&"&Boardname="&Boardname)108 Rs.Close109 Set Rs=Nothing110 111 End Sub112 113 114 If style="del" Then115 'Conn.Execute("update Content set IsDel=1 where Id in("&Id&")")116 Conn.Execute(" Delete * From Content where Id in("&Id&")")117 Call Show_Msg("删除成功!","Public_List.asp?Boardid="&Boardid&"&Boardname="&Boardname)118 End If119 120 Select Case action121 Case "DoAdd" Call Do_Add(BoardId)122 Case "DoEdit" Call Do_Edit(Id)123 End Select124 %>

 

转载于:https://www.cnblogs.com/cykj/p/ASP-enterprise-website-source-part.html

你可能感兴趣的文章
前端常见问题整理
查看>>
Android进程保活招数概览
查看>>
iOS拨打电话对话框问题解决
查看>>
Material过渡+Glide显示问题踩坑
查看>>
新浪微博API生成短链接
查看>>
c++ ignore
查看>>
如何解读决策树和随机森林的内部工作机制?
查看>>
别的设计师都下班撸串去了,你却还在右击另存为?
查看>>
使用Selenium+POI实现Excel自动化批量查单词
查看>>
0510 - 不贴标签,勿论长短
查看>>
java 源码分析 ---Byte
查看>>
PHP实现get/post请求中的注意点
查看>>
go开发属于自己的日志库-文件日志库实现
查看>>
Spring+SpringMVC+Mybatis框架整合步骤
查看>>
JavaScript中的for in循环
查看>>
[译] 系统设计入门 | 掘金翻译计划
查看>>
阿里P7大牛细说架构——设计模式专栏
查看>>
手把手教你在本地构建 Nervos AppChain 全家桶
查看>>
聊聊对称/非对称加密在HTTPS中的应用
查看>>
「 iOS知识小集 」2018 · 第 35 期
查看>>