摘要: declare @idoc intdeclare @doc varchar(1000)--sample xml documentset @doc ='<root> <customer cid= "c1" name="janine" city="issaquah"> <order oid="o1" d 阅读全文
posted @ 2018-06-08 17:19 黑旗君 阅读(157) 评论(0) 推荐(0)
摘要: <script language="javascript">function checkall(form) { for (var i=0;i<form.elements.length;i++) { var e = form.elements[i]; if (e.name != "chkall"&&e 阅读全文
posted @ 2018-06-08 17:19 黑旗君 阅读(343) 评论(0) 推荐(0)
摘要: ******* 导出到excel exec master..xp_cmdshell 'bcp settledb.dbo.shanghu out c:\temp1.xls -c -q -s"gnetdata/gnetdata" -u"sa" -p""'/*********** 导入excel sele 阅读全文
posted @ 2018-06-08 17:18 黑旗君 阅读(278) 评论(0) 推荐(0)
摘要: set xlapp = server.createobject("excel .application")strsource=filepath & "test.xls"'打开一个已经存在的test.xls文件,filepath为物理绝对路径xlapp.workbooks.open(strsource 阅读全文
posted @ 2018-06-08 17:17 黑旗君 阅读(654) 评论(0) 推荐(0)
摘要: 文件aspprint.asp代码如下: <%@ language=vbscript %> <% option explicit dim strsubmit 'form中用来保存提交按钮的值 dim strprinterpath 'form中保存网络打印机路径的值 dim strusername 'f 阅读全文
posted @ 2018-06-08 17:16 黑旗君 阅读(513) 评论(0) 推荐(0)
摘要: 目录 一、 环境配置 二、 asp对excel 的基本操作 三、 asp操作excel 生成数据表 四、 asp操作excel 生成chart图 五、 服务器端excel 文件浏览、下载、删除方案 六、 附录正文 一、 环境配置 服务器端的环境配置从参考资料上看,微软系列的配置应该都行,即: 1.w 阅读全文
posted @ 2018-06-08 17:14 黑旗君 阅读(4907) 评论(0) 推荐(0)
摘要: 1.获得系统时间:<%=now()%>2.取得来访用的ip:<%=request.servervariables("remote_host")%>3.获得系统,浏览器版本:<script>window.document.write("版本:"+navigator.appname+navigator. 阅读全文
posted @ 2018-06-08 17:13 黑旗君 阅读(365) 评论(0) 推荐(0)
摘要: 一、asp的对象存取其他数据库 方法 在asp中,用来存取其他数据库 的对象统称ado(active data objects),主要含有三种对象: connection、recordset 、command connection:负责打开或连接数据 recordset:负责存取数据表 comman 阅读全文
posted @ 2018-06-08 17:12 黑旗君 阅读(252) 评论(0) 推荐(0)
摘要: <script language=javascript>var srcc = window.location; srcc = srcc.tostring()start = srcc.indexof("?"); end = srcc.length;</script> <script>alert(loc 阅读全文
posted @ 2018-06-08 17:09 黑旗君 阅读(144) 评论(0) 推荐(0)
摘要: <%yue=month(date())nian=year(date())thismon=nian&"-"&yue&"-1"nextmon=dateadd("m",1,thismon)tiancount=datediff("d",thismon,nextmon) '本月的天数 wek= weekday 阅读全文
posted @ 2018-06-08 14:56 黑旗君 阅读(542) 评论(0) 推荐(0)
摘要: 1.如何用asp判断你的网站的虚拟物理路径 答:使用mappath方法 < p align="center" >< font size="4" face="arial" >< b > the physical path to this virtual website is: < /b >< /fon 阅读全文
posted @ 2018-06-08 14:55 黑旗君 阅读(336) 评论(0) 推荐(0)
摘要: 1。忽视右键 <body oncontextmenu="return false"> 或 <body style="overflow-y:hidden"> 2。加入背景音乐 ie:<bgsound src="*.mid" loop=infinite> ns:<embed src="*.mid" au 阅读全文
posted @ 2018-06-08 14:54 黑旗君 阅读(8462) 评论(0) 推荐(0)
摘要: oncontextmenu="window.event.returnvalue=false" 将彻底屏蔽鼠标右键<table border oncontextmenu=return(false)><td>no</table> 可用于table 2. <body onselectstart="retu 阅读全文
posted @ 2018-06-08 14:52 黑旗君 阅读(492) 评论(0) 推荐(0)
摘要: <% set rss=server.createobject("adodb.recordset") ssql="select * from [dormitory] left join [allot] on allot.r_id=dormitory.r_id and dormitory.build=a 阅读全文
posted @ 2018-06-08 12:00 黑旗君 阅读(215) 评论(0) 推荐(0)
摘要: <% squery=lcase(Request.ServerVariables("QUERY_STRING")) sURL=lcase(Request.ServerVariables("HTTP_HOST")) SQL_injdata =":|;|>|<|--|sp_|xp_|\|dir|cmd|^ 阅读全文
posted @ 2018-06-08 11:59 黑旗君 阅读(269) 评论(0) 推荐(0)
摘要: <% Dim Fy_Post,Fy_Get,Fy_cook,Fy_In,Fy_Inf,Fy_Xh,Fy_db,Fy_dbstr,aa On Error Resume Next Fy_In = "'|exec|insert|select|delete|update|count|chr|truncate 阅读全文
posted @ 2018-06-08 11:58 黑旗君 阅读(3824) 评论(0) 推荐(0)
摘要: <%'定义一个nextrs函数来找出下一篇的IDfunction nrsnrs=server.CreateObject("adodb.recordset")sql="select * from articles where id>"&a1&" order by id"set nrs=conn.exe 阅读全文
posted @ 2018-06-08 11:55 黑旗君 阅读(304) 评论(0) 推荐(0)
摘要: <%set rs=server.CreateObject("adodb.recordset")sql="select * from [student_admin] order by id DESC"rs.open sql,conn,1,3%><%rs.pagesize=15'这个是显示最新的8条记录 阅读全文
posted @ 2018-06-08 11:41 黑旗君 阅读(500) 评论(0) 推荐(0)
摘要: <%set rs=server.createobject("adodb.recordset")sql="select * from [img] order by id DESC"rs.open sql,conn,1,3%><%rs.pagesize=10pagecount=rs.pagecountp 阅读全文
posted @ 2018-06-08 11:34 黑旗君 阅读(264) 评论(0) 推荐(0)
摘要: <% if session("mm_username")="" Then Response.Write "<script>window.confirm('登陆超时!');parent.window.history.go(-1);location='login.asp'</script>" end i 阅读全文
posted @ 2018-06-08 11:32 黑旗君 阅读(473) 评论(0) 推荐(0)
摘要: <% if trim(request("action"))="add" then if request.form("cn_name1")=Empty or request.Form("pwd")=Empty or request.Form("pwd2")=Empty or request.Form( 阅读全文
posted @ 2018-06-08 11:30 黑旗君 阅读(311) 评论(0) 推荐(0)
摘要: <% Session("mm_username")="" Response.Cookies("mm_username")="" response.write"<script>alert('成功退出系统!');location='index.asp'</script>" %> 阅读全文
posted @ 2018-06-08 11:29 黑旗君 阅读(216) 评论(0) 推荐(0)
摘要: <% dim name,pwd name=trim(request("name")) pwd=trim(request("pwd")) if name=”” or pwd=”” then response.Write "<script>alert('账户密码不能为空!');location='man 阅读全文
posted @ 2018-06-08 11:28 黑旗君 阅读(429) 评论(0) 推荐(0)
摘要: 自动弹出对话框 <%Response.Write "<script language='javascript'>alert('删除成功!');</script>"%> 执行链接提示对话框 <a href="1.asp" onClick="return confirm('您确定进行删除操作吗?')"> 阅读全文
posted @ 2018-06-08 11:12 黑旗君 阅读(753) 评论(0) 推荐(0)
摘要: <!--#include file="conn.asp" --> 阅读全文
posted @ 2018-06-08 11:11 黑旗君 阅读(125) 评论(0) 推荐(0)
摘要: <% set rs=server.createobject("adodb.recordset") exec="delete * from [guide] where id="&request.querystring("id") rs.open exec,conn,3,2 Response.Write 阅读全文
posted @ 2018-06-08 11:10 黑旗君 阅读(183) 评论(0) 推荐(0)
摘要: <% title=trim(request("title")) title=request.Form("title") cont=request.Form("cont") time1=request.Form("time1") publisher=request.Form("publisher") 阅读全文
posted @ 2018-06-08 11:09 黑旗君 阅读(319) 评论(0) 推荐(0)
摘要: <% if trim(request("action"))="add" then set rs=server.CreateObject("adodb.recordset") rs.open "select * from [news]",conn,1,3 rs.addnew rs("title")=r 阅读全文
posted @ 2018-06-08 11:07 黑旗君 阅读(202) 评论(0) 推荐(0)
摘要: 数据动态传递 <a href="<%=rs(“url”)%>" title="<%=rs("title")%>" target="_blank"><%=rs("title")%></a> 或 <a href="123.asp" title="<%=rs("title")%>" target="_bl 阅读全文
posted @ 2018-06-08 11:06 黑旗君 阅读(101) 评论(0) 推荐(0)
摘要: <% set rs=server.createobject("adodb.recordset") sql="select * from recruitment where audit='审核通过' order by id DESC" rs.open sql,conn,1,1 %> 数据输出 <%=r 阅读全文
posted @ 2018-06-08 11:04 黑旗君 阅读(594) 评论(0) 推荐(0)
摘要: “排序” <% set rs=server.createobject("adodb.recordset") sql="select * from [session] order by id DESC" rs.open sql,conn,1,1 %> order by为数据排序,DESC降序,ASC升 阅读全文
posted @ 2018-06-08 11:02 黑旗君 阅读(548) 评论(0) 推荐(0)
摘要: <% Set conn = Server.CreateObject("ADODB.Connection") connstr="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath("/mydate.mdb") conn.ope 阅读全文
posted @ 2018-06-08 10:59 黑旗君 阅读(227) 评论(0) 推荐(0)