<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
<channel>
<title><![CDATA[KeKe's Blog]]></title>
<link>http://www.kekecn.com/blog/</link>
<description><![CDATA[红心男孩的技术博客]]></description>
<language>zh-cn</language>
<copyright><![CDATA[Copyright 2005 PBlog3 v2.8]]></copyright>
<webMaster><![CDATA[kekecn@gmail.com(红心男孩)]]></webMaster>
<generator>PBlog2 v2.4</generator> 
<image>
	<title>KeKe&#39;s Blog</title>
	<url>http://www.kekecn.com/blog/images/logos.gif</url>
	<link>http://www.kekecn.com/blog/</link>
	<description>KeKe&#39;s Blog</description>
</image>

			<item>
			<link>http://www.kekecn.com/blog/article.asp?id=896</link>
			<title><![CDATA[ecshop在模板里调用广告位的代码]]></title>
			<author>kekecn@gmail.com(红心男孩)</author>
			<category><![CDATA[Asp&amp;PHP]]></category>
			<pubDate>Wed,10 Mar 2010 09:16:16 +0800</pubDate>
			<guid>http://www.kekecn.com/blog/default.asp?id=896</guid>
		<description><![CDATA[在后台添加广告位置，然后在该广告位置下添加广告（注意：每个广告位置下加一个广告），记住该广告位置的ID，然后在模板中加入下面代码即可<br/><br/>{ins&#101;rt name=&#39;ads&#39; id=2 num=1}<br/><br/>ID：广告位置ID<br/>num:显示数量<br/><br/>推荐(0)(收藏)]]></description>
		</item>
		
			<item>
			<link>http://www.kekecn.com/blog/article.asp?id=895</link>
			<title><![CDATA[多个二级域名共享cookies实现多站同步登录数据]]></title>
			<author>kekecn@gmail.com(红心男孩)</author>
			<category><![CDATA[Asp&amp;PHP]]></category>
			<pubDate>Sat,26 Sep 2009 15:59:03 +0800</pubDate>
			<guid>http://www.kekecn.com/blog/default.asp?id=895</guid>
		<description><![CDATA[这段时间有个客户要实现多个子域名之间的登陆同步，在一群里也讨论了下，发现可以通过共享Cookies的方法来实现，在网上搜索了下，发现如下贴子。于时转过来。<br/><br/>一个网站，同步登陆信息，实现多个栏目的跨越，是一件很人性化的事情。但是，如果一旦遇到了二级域名，那这个跨站登陆，因为不同的域名下面的cookies不一样，所以这个一般无法做大，但是有一种方法可以顺利实现，步骤如下：<br/><br/>1、在iis新建站点3个<br/>www.kekecn.com(和kekecn.com)，img.kekecn.com，blog.kekecn.com<br/><br/>2、在www.kekecn.com下建立文件testcookies.asp,代码如下：<br/><div class="UBBPanel codePanel"><div class="UBBTitle"><a onClick="copycode(code5727);" style="float:right;cursor: pointer;font-weight: normal; font-style: normal">复制内容到剪贴板</a><img src="http://www.kekecn.com/blog/images/code.gif" style="margin:0px 2px -3px 0px;" alt="程序代码"/> 程序代码</div><div class="UBBContent" id=code5727><br/>&lt;% <br/>Response.Cookies(&#34;Type&#34;) = &#34;Test Cookies&#34;<br/>Response.Cookies(&#34;Type&#34;).Expires = date()+30<br/>Response.Cookies(&#34;Type&#34;).Domain = &#34;.kekecn.com&#34;<br/>Response.Cookies(&#34;Type&#34;).Secure = False<br/>Response.Write Request.Cookies(&#34;Type&#34;)<br/>%&gt;<br/></div></div><br/><br/>3、在ad.kekecn.com下建立文件testcookies.asp，代码如下：<br/><div class="UBBPanel codePanel"><div class="UBBTitle"><a onClick="copycode(code82892);" style="float:right;cursor: pointer;font-weight: normal; font-style: normal">复制内容到剪贴板</a><img src="http://www.kekecn.com/blog/images/code.gif" style="margin:0px 2px -3px 0px;" alt="程序代码"/> 程序代码</div><div class="UBBContent" id=code82892><br/>&lt;%Response.Write Request.Cookies(&#34;Type&#34;)%&gt;<br/></div></div><br/><br/><br/>4、在blog.kekecn.com下建立文件testcookies.asp，代码同上<br/>5、因为是本机测试，修改hosts文件，把4个域名都指向到127.0.0.1，也就是添加如下内容：<br/>&nbsp;&nbsp; 127.0.0.1&nbsp;&nbsp;&nbsp;&nbsp; ad.kekecn.com<br/>&nbsp;&nbsp;&nbsp;&nbsp;127.0.0.1&nbsp;&nbsp;&nbsp;&nbsp; blog.kekecn.com<br/>&nbsp;&nbsp;&nbsp;&nbsp;127.0.0.1&nbsp;&nbsp;&nbsp;&nbsp; www.kekecn.com<br/>&nbsp;&nbsp;&nbsp;&nbsp;127.0.0.1&nbsp;&nbsp;&nbsp;&nbsp; kekecn.com<br/>6、关闭所有浏览器，开ie,打开<a href="http://www.kekecn.com/demo/testcookies.asp" target="_blank" rel="external">http://www.kekecn.com/demo/testcookies.asp</a>，显示出文本内容：Test Cookies<br/>7、新建窗口，打开<a href="http://ad.kekecn.com/temp/testcookies.asp" target="_blank" rel="external">http://ad.kekecn.com/temp/testcookies.asp</a>，显示出文本内容：Test Cookies<br/>8、新建窗口，打开<a href="http://blog.kekecn.com/temp/testcookies.asp" target="_blank" rel="external">http://blog.kekecn.com/temp/testcookies.asp</a>，同样显示出如上文本内容<br/>9、换其他4个浏览器，都成功。<br/><br/>注意点：<br/>1、Response.Cookies(&#34;Type&#34;).Secure = False，Secure属性一定要是false，或者直接不执行这行，如果Secure = True，则ad和blog的2级域名是取值不了。<br/>2、Response.Cookies(&#34;Type&#34;).Domain = &#34;.kekecn.com&#34;，domain的值，我设置为&#34;kekecn.com&#34;，也就是没有前面的点，在IE下成功<br/>其他4个浏览器没测试。<br/>3、path我猜是不应该设置的。<br/>4、在局域网内其他机器上，修改host指向到我机器的IP，取值成功。<br/>5、在局域网另外一台机器上架设ad.kekecn.com，把testcookies.asp文件copy过去，同时修改host到当前机器，取值成功<br/><br/>按照这样的方法，就可以顺利的实现了多个二级域名共享cookies实现多站同步登录数据。 ]]></description>
		</item>
		
			<item>
			<link>http://www.kekecn.com/blog/article.asp?id=894</link>
			<title><![CDATA[动画效果打开层 关闭层]]></title>
			<author>kekecn@gmail.com(红心男孩)</author>
			<category><![CDATA[Html&amp;JS]]></category>
			<pubDate>Sat,26 Sep 2009 03:32:07 +0800</pubDate>
			<guid>http://www.kekecn.com/blog/default.asp?id=894</guid>
		<description><![CDATA[<div class="UBBPanel"><div class="UBBTitle"><img src="http://www.kekecn.com/blog/images/html.gif" style="margin:0px 2px -3px 0px"> HTML代码</div><div class="UBBContent"><TEXTAREA rows="8" id="temp34268">
<html xmlns=&#34;<a href="http://www.w3.org/1999/xhtml" target="_blank" rel="external">http://www.w3.org/1999/xhtml</a>&#34;>
<head>
<meta http-equiv=&#34;Content-Type&#34; content=&#34;text/html; charset=gb2312&#34; />
<title>DOM_text01</title>
<style type=&#34;text/css&#34;>
body,span,div,td{font-size:12px;line-height:1.5em;color:#849BCA;}
#bodyL{
	float:left;
	width:84px;
	margin-right:2px;
}
a.od{
	width:80px;
	height:25px;
	line-height:25px;
	text-align:center;
	font-weight:bold;
	border: 2px solid #849BCA;	
	display:block;
	color:#547BC9;
	float:left;
	text-decoration:none;
	margin-top:2px;
}
a.od:link{
	background:#EEF1F8;
}
a.od:visited{
	background:#EEF1F8;
}
a.od:hover{
	background:#EEE;
}
a.od:active{
	background:#EEE;
}
#fd{	
	width:500px;
	height:200px;
	background:#EDF1F8;	
	border: 2px solid #849BCA;
	margin-top:2px;
	margin-left:2px;
	float:left;
	overflow:hidden;
	position:absolute;
	left:0px;
	top:0px;
	cursor:move;
	float:left;
	/*filter:alpha(opacity=50);*/
	
}
.content{
	padding:10px;
}
</style>
</head>
<body>
<div id=&#34;bodyL&#34;>













	<a href=&#34;#&#34; class=&#34;od&#34; id=&#34;a&#34; onclick=&#34;document.getElementById('b').style.display = 'block';this.style.display = 'none';show('fd');&#34;/>[打开层]</a>
	<a href=&#34;#&#34; class=&#34;od&#34; style=&#34;display:none;&#34; id=&#34;b&#34; onclick=&#34;document.getElementById('a').style.display = 'block';this.style.display = 'none';closeed('fd');&#34;/>[关闭层]</a>
</div>	
<div id=&#34;fd&#34; style=&#34;display:none;filter:alpha(opacity=100);opacity:1;&#34;>
	<div class=&#34;content&#34;>移动层</div>	
</div>
	
<script type=&#34;text/javascript&#34;>
	var prox;
	var proy;
	var proxc;
	var proyc;
	function show(id){/*--打开--*/
		clearInterval(prox);
		clearInterval(proy);
		clearInterval(proxc);
		clearInterval(proyc);
		var o = document.getElementById(id);
		o.style.display = &#34;block&#34;;
		o.style.width = &#34;1px&#34;;
		o.style.height = &#34;1px&#34;; 
		prox = setInterval(function(){openx(o,500)},10);
	}	
	function openx(o,x){/*--打开x--*/
		var cx = parseInt(o.style.width);
		if(cx < x)
		{
			o.style.width = (cx + Math.ceil((x-cx)/5)) +&#34;px&#34;;
		}
		else
		{
			clearInterval(prox);
			proy = setInterval(function(){openy(o,200)},10);
		}
	}	
	function openy(o,y){/*--打开y--*/	
		var cy = parseInt(o.style.height);
		if(cy < y)
		{
			o.style.height = (cy + Math.ceil((y-cy)/5)) +&#34;px&#34;;
		}
		else
		{
			clearInterval(proy);			
		}
	}	
	function closeed(id){/*--关闭--*/
		clearInterval(prox);
		clearInterval(proy);
		clearInterval(proxc);
		clearInterval(proyc);		
		var o = document.getElementById(id);
		if(o.style.display == &#34;block&#34;)
		{
			proyc = setInterval(function(){closey(o)},10);			
		}		
	}	
	function closey(o){/*--打开y--*/	
		var cy = parseInt(o.style.height);
		if(cy > 0)
		{
			o.style.height = (cy - Math.ceil(cy/5)) +&#34;px&#34;;
		}
		else
		{
			clearInterval(proyc);				
			proxc = setInterval(function(){closex(o)},10);
		}
	}	
	function closex(o){/*--打开x--*/
		var cx = parseInt(o.style.width);
		if(cx > 0)
		{
			o.style.width = (cx - Math.ceil(cx/5)) +&#34;px&#34;;
		}
		else
		{
			clearInterval(proxc);
			o.style.display = &#34;none&#34;;
		}
	}	
	
	
	/*-------------------------鼠标拖动---------------------*/	
	var od = document.getElementById(&#34;fd&#34;);	
	var dx,dy,mx,my,mouseD;
	var odrag;
	var isIE = document.all ? true : false;
	document.onmousedown = function(e){
		var e = e ? e : event;
		//if(e.button == (document.all ? 1 : 0))
		//{
			mouseD = true;			
		//}
	}
	document.onmouseup = function(){
		mouseD = false;
		odrag = &#34;&#34;;
		if(isIE)
		{
		
			od.filters.alpha.opacity = 100;
		}
		else
		{
			
			od.style.opacity = 1;
		}		
	}
	
	
	//function readyMove(e){	
	od.onmousedown = function(e){
		odrag = this;
		var e = e ? e : event;
		//if(e.button == (document.all ? 1 : 0))
		//{
			mx = e.clientX;
			my = e.clientY;
			od.style.left = od.offsetLeft + &#34;px&#34;;
			od.style.top = od.offsetTop + &#34;px&#34;;
			if(isIE)
			{
						
				od.filters.alpha.opacity = 50;
			}
			else
			{
				
				od.style.opacity = 0.5;
			}
			
			//alert(mx);
			//alert(my);
			
		//} 
	}
	document.onmousemove = function(e){
		var e = e ? e : event;
		//alert(mrx);
		//alert(e.button);		
		if(odrag)
		{		
			var mrx = e.clientX - mx;
			var mry = e.clientY - my;	
			od.style.left = parseInt(od.style.left) +mrx + &#34;px&#34;;
			od.style.top = parseInt(od.style.top) + mry + &#34;px&#34;;			
			mx = e.clientX;
			my = e.clientY;
			
		}
	}
	
	
</script>
</body>
</html>
</TEXTAREA><br/><INPUT onclick="runEx('temp34268')"  type="button" class="userbutton" value="运行此代码"/> <INPUT onclick="doCopy('temp34268')"  type="button" class="userbutton" value="复制此代码"/> <INPUT onclick="saveCode('temp34268')" type="button" class="userbutton" value="保存此代码"><br/> [Ctrl+A 全部选择 提示：你可先修改部分代码，再按运行]</div></div>]]></description>
		</item>
		
			<item>
			<link>http://www.kekecn.com/blog/article.asp?id=893</link>
			<title><![CDATA[控制层的顺序]]></title>
			<author>kekecn@gmail.com(红心男孩)</author>
			<category><![CDATA[Html&amp;JS]]></category>
			<pubDate>Sat,26 Sep 2009 02:56:08 +0800</pubDate>
			<guid>http://www.kekecn.com/blog/default.asp?id=893</guid>
		<description><![CDATA[<div class="UBBPanel"><div class="UBBTitle"><img src="http://www.kekecn.com/blog/images/html.gif" style="margin:0px 2px -3px 0px"> HTML代码</div><div class="UBBContent"><TEXTAREA rows="8" id="temp49886">
<html> 
<head> 
<title> </title> 
<style> 
.myclass{position:absolute;width:300;height:200;} 
</style> 
<script> 
function repos(){ 
var e = event.srcElement; 
if(e.tagName==&#34;DIV&#34;){ 
var o=document.getElementsByTagName(&#34;DIV&#34;); 
var n = o.length; 
for(var i=0;i<o.length;i++) 
if(o[i].style.zIndex == n) o[i].style.zIndex-=1; 

e.style.zIndex = n; 
} 
} 
</script> 
</head> 
<body onclick=&#34;repos()&#34;> 
<div class=myclass style=&#34;left:100;top:100;background-color:red;z-index:1&#34;> 
div1 div1 div1</div> 
<div class=myclass style=&#34;left:120;top:120;background-color:yellow;z-index:2&#34;> 
222222222222 2222222222</div> 
<div class=myclass style=&#34;left:150;top:150;background-color:green;z-index:3&#34;> 
33333333333333</div> 
<div class=myclass style=&#34;left:170;top:190;background-color:cyan;z-index:4&#34;> 
444444444444444</div> 
</body> 
</html> 
</TEXTAREA><br/><INPUT onclick="runEx('temp49886')"  type="button" class="userbutton" value="运行此代码"/> <INPUT onclick="doCopy('temp49886')"  type="button" class="userbutton" value="复制此代码"/> <INPUT onclick="saveCode('temp49886')" type="button" class="userbutton" value="保存此代码"><br/> [Ctrl+A 全部选择 提示：你可先修改部分代码，再按运行]</div></div>]]></description>
		</item>
		
			<item>
			<link>http://www.kekecn.com/blog/article.asp?id=892</link>
			<title><![CDATA[数据库内容被挂马的处理办法]]></title>
			<author>kekecn@gmail.com(红心男孩)</author>
			<category><![CDATA[Asp&amp;PHP]]></category>
			<pubDate>Mon,21 Sep 2009 04:40:36 +0800</pubDate>
			<guid>http://www.kekecn.com/blog/default.asp?id=892</guid>
		<description><![CDATA[数据库被挂马我相信很多人都碰到过。在这里，我讲下我处理的方法。<br/>第一步：为现有数据库做好备份。<br/>第二步：<br/>执行如下ASP文件，这样就可以去掉数据库当中的ASP木马：<br/>注：conn.asp自己去写了。<br/><div class="UBBPanel codePanel"><div class="UBBTitle"><a onClick="copycode(code93452);" style="float:right;cursor: pointer;font-weight: normal; font-style: normal">复制内容到剪贴板</a><img src="http://www.kekecn.com/blog/images/code.gif" style="margin:0px 2px -3px 0px;" alt="程序代码"/> 程序代码</div><div class="UBBContent" id=code93452><br/>&#39;这里放入JS木马内容：请记得改为自己数据库中的JS木马内容。<br/>&lt;!--#include file=&#34;conn.asp&#34;--&gt;<br/>&lt;%<br/>Server.ScriptTimeOut=180<br/>Set rstSchema = conn.OpenSchema(20)<br/>k=1<br/>Do Until rstSchema.EOF &#39;遍历数据库表<br/>&#160;&#160;&#160;&#160;If rstSchema(&#34;TABLE_TYPE&#34;)=&#34;TABLE&#34; Then <br/>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;response.write K&amp;&#34;.&lt;font color=red&gt;&lt;b&gt;&#34;&amp;rstSchema(&#34;TABLE_NAME&#34;) &amp; &#34;&lt;/b&gt;&lt;/font&gt;:&#34; &#39;显示表名<br/>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;Set rs=Server.Cr&#101;ateObject(&#34;ADODB.Recordset&#34;)<br/>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;sql=&#34;sel&#101;ct * from [&#34; &amp; rstSchema(&#34;TABLE_NAME&#34;)&amp;&#34;]&#34;<br/>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;rs.open sql,conn,1,3<br/>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;For i=0 to rs.fields.count-1 &#39;遍历表中字段<br/>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&nbsp;&nbsp; If int(rs(i).Type)=129 o&#114; int(rs(i).Type)=130 o&#114; int(rs(i).Type)=200 o&#114; int(rs(i).Type)=201 o&#114; int(rs(i).Type)=202 o&#114; int(rs(i).Type)=203 Then&#39;只处理字段类型为字符型的字段<br/>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;conn.execute(&#34;up&#100;ate [&#34;&amp;rstSchema(&#34;TABLE_NAME&#34;)&amp;&#34;] set &#34;&amp;rs(i).name&amp;&#34; =replace(cast(&#34;&amp;rs(i).name&amp;&#34; as varchar(8000)),&#39;这里放入JS木马内容&#39;,&#39;&#39;)&#34;)<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;response.write rs(i).name &amp;&#34; &#34;&amp;rs(i).Type &amp;&#34; &#34;&#39;显示执行过的字段名。<br/>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&nbsp;&nbsp;End If<br/>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;Next<br/>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;response.write &#34;&lt;br&gt;&#34; <br/>&#160;&#160;&#160;&#160;End If <br/>&#160;&#160;&#160;&#160;rstSchema.MoveNext<br/>&#160;&#160;&#160;&#160;k=k+1<br/>Loop<br/>response.Write &#34;执行成功&#34;<br/>%&gt;<br/></div></div><br/><br/>如果数据库表很多的话，上面的遍历数据库结构未执行完就被IIS给停止了。在这时候可以在<br/><div class="UBBPanel codePanel"><div class="UBBTitle"><a onClick="copycode(code44059);" style="float:right;cursor: pointer;font-weight: normal; font-style: normal">复制内容到剪贴板</a><img src="http://www.kekecn.com/blog/images/code.gif" style="margin:0px 2px -3px 0px;" alt="程序代码"/> 程序代码</div><div class="UBBContent" id=code44059><br/>If rstSchema(&#34;TABLE_TYPE&#34;)=&#34;TABLE&#34; Then<br/></div></div><br/>当中适当加入k值的范围，如：<br/><div class="UBBPanel codePanel"><div class="UBBTitle"><a onClick="copycode(code65681);" style="float:right;cursor: pointer;font-weight: normal; font-style: normal">复制内容到剪贴板</a><img src="http://www.kekecn.com/blog/images/code.gif" style="margin:0px 2px -3px 0px;" alt="程序代码"/> 程序代码</div><div class="UBBContent" id=code65681><br/>If rstSchema(&#34;TABLE_TYPE&#34;)=&#34;TABLE&#34; k&gt;10 and k&lt;20 Then<br/></div></div><br/>这样的话就一次只操作9个表。<br/><br/>第三步：<br/>根据数据库JS注入的特性(会包括&lt;script、&lt;/script&gt;和<a href="http://" target="_blank" rel="external">http://</a>这样的字符)，<br/>在conn.asp里面放入如下代码：<br/><br/><div class="UBBPanel codePanel"><div class="UBBTitle"><a onClick="copycode(code53931);" style="float:right;cursor: pointer;font-weight: normal; font-style: normal">复制内容到剪贴板</a><img src="http://www.kekecn.com/blog/images/code.gif" style="margin:0px 2px -3px 0px;" alt="程序代码"/> 程序代码</div><div class="UBBContent" id=code53931><br/>Function Cheack_Sqljs()&#39;防止数据库外链JS注入:true为发现外链JS注入。<br/>&nbsp;&nbsp;&nbsp;&nbsp;Dim F_Post,F_Get,F_Cookies<br/>&nbsp;&nbsp;&nbsp;&nbsp;Cheack_Sqljs=False<br/>&nbsp;&nbsp;&nbsp;&nbsp;If Request.Form&lt;&gt;&#34;&#34; Then&#39;表单提交时的检测<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;For Each F_Post In Request.Form<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;If (Instr(LCase(Request.Form(F_Post)),&#34;&lt;script&#34;)&lt;&gt;0 o&#114; Instr(LCase(Request.Form(F_Post)),&#34;&lt;/script&gt;&#34;)&lt;&gt;0) and Instr(LCase(Request.Form(F_Post)),&#34;<a href="http://" target="_blank" rel="external">http://</a>&#34;)&lt;&gt;0 Then<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cheack_Sqljs=True<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Exit For<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;End If<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Next<br/>&nbsp;&nbsp;&nbsp;&nbsp;End If<br/>&nbsp;&nbsp;&nbsp;&nbsp;If Request.QueryString&lt;&gt;&#34;&#34; Then&#39;QueryString提交时的检测<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;For Each F_Get In Request.QueryString<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;If (Instr(LCase(Request.QueryString(F_Get)),&#34;&lt;script&#34;)&lt;&gt;0 o&#114; Instr(LCase(Request.QueryString(F_Get)),&#34;&lt;/script&gt;&#34;)&lt;&gt;0) and Instr(LCase(Request.QueryString(F_Get)),&#34;<a href="http://" target="_blank" rel="external">http://</a>&#34;)&lt;&gt;0 Then<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cheack_Sqljs=True<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Exit For<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;End If<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Next<br/>&nbsp;&nbsp;&nbsp;&nbsp;End If<br/>&#160;&#160;&#160;&#160;<br/>&nbsp;&nbsp;&nbsp;&nbsp;If Request.Cookies&lt;&gt;&#34;&#34; Then&#39;COOKIE提交时的检测<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;For Each F_Cookies In Request.Cookies<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;If (Instr(LCase(Request.Cookies(F_Cookies)),&#34;&lt;script&#34;)&lt;&gt;0 o&#114; Instr(LCase(Request.Cookies(F_Cookies)),&#34;&lt;/script&gt;&#34;)&lt;&gt;0) and Instr(LCase(Request.Cookies(F_Cookies)),&#34;<a href="http://" target="_blank" rel="external">http://</a>&#34;)&lt;&gt;0 Then<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cheack_Sqljs=True<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Exit For<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;End If<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Next<br/>&nbsp;&nbsp;&nbsp;&nbsp;End If<br/>End Function<br/><br/>Function CheckDataFrom()&#39;检查提交数据来源：True为数据从站外提交过来的<br/>&#160;&#160;&#160;&#160;CheckDataFrom=False<br/>&#160;&#160;&#160;&#160;server_v1=Cstr(Request.ServerVariables(&#34;HTTP_REFERER&#34;))<br/>&#160;&#160;&#160;&#160;server_v2=Cstr(Request.ServerVariables(&#34;SERVER_NAME&#34;))<br/>&#160;&#160;&#160;&#160;if server_v1&lt;&gt;&#34;&#34; and mid(server_v1,8,len(server_v2))&lt;&gt;server_v2 then<br/>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;CheckDataFrom=True<br/>&#160;&#160;&#160;&#160;end if<br/>End Function<br/>If Cheack_Sqljs o&#114; CheckDataFrom Then<br/>&nbsp;&nbsp; Response.Write &#34;&lt;Script Language=JavaScript&gt;alert(&#39;禁止执行，非法操作。&#39;);&lt;/Script&gt;&#34; <br/>&nbsp;&nbsp; Response.End()<br/>End If<br/></div></div>]]></description>
		</item>
		
			<item>
			<link>http://www.kekecn.com/blog/article.asp?id=891</link>
			<title><![CDATA[前段时间博客竟然被挂马了。]]></title>
			<author>kekecn@gmail.com(红心男孩)</author>
			<category><![CDATA[Diary]]></category>
			<pubDate>Thu,17 Sep 2009 01:42:33 +0800</pubDate>
			<guid>http://www.kekecn.com/blog/default.asp?id=891</guid>
		<description><![CDATA[前段时间博客竟然被挂马了。。一直想换个博客程序，想换成WP。但是可惜了。我这800多贴子经过LBLOG导PJBLOG。现在由PJBLOG导WP竟然会出错。。在这种无语的情况下。只能继续使用PJ了。。。郁闷中。呵。。只能跟着PJ博客的节奏去升级。。]]></description>
		</item>
		
			<item>
			<link>http://www.kekecn.com/blog/article.asp?id=888</link>
			<title><![CDATA[泛解析和伪静态实现二级域名]]></title>
			<author>kekecn@gmail.com(红心男孩)</author>
			<category><![CDATA[Asp&amp;PHP]]></category>
			<pubDate>Fri,19 Jun 2009 11:41:02 +0800</pubDate>
			<guid>http://www.kekecn.com/blog/default.asp?id=888</guid>
		<description><![CDATA[比如顶级域名为www.aa.com<br/>现在在实现用username.aa.com访问用户username的信息页面。实际路径为：aa.com/user/index.asp?user=username<br/><br/>前提条件：1.必须有独立IP的服务器或者虚拟主机&nbsp;&nbsp;2.支持伪静态。<br/>实现办法：<br/>第一步：实现泛解析<br/><br/>在服务器的IIS上不做任何绑定域名的操作。让直接输入IP地址可以访问到站点。。然后在域名控制面板做*指向就OK了。<br/><br/>第二步：<br/>在httpd.ini中加入<br/><br/>RewriteCond Host: (?!www|bbs)([^.]+).aa.com<br/>RewriteRule (.*) /user/index.asp\?user=$1<br/><br/>这样就完成了。够简单吧：）<br/><br/>以上只是思路，大家需根据自己情况做相应正则调整。]]></description>
		</item>
		
			<item>
			<link>http://www.kekecn.com/blog/article.asp?id=887</link>
			<title><![CDATA[下拉列表新窗品打开]]></title>
			<author>kekecn@gmail.com(红心男孩)</author>
			<category><![CDATA[Html&amp;JS]]></category>
			<pubDate>Mon,09 Mar 2009 22:28:44 +0800</pubDate>
			<guid>http://www.kekecn.com/blog/default.asp?id=887</guid>
		<description><![CDATA[我想经常有朋友会碰到下拉菜单里面放友情链接的需求，但是如果在下拉选择之后用location.href跳转的话，是在本页跳转。如果想要让友情链接在新窗口大家应该都会想到用window.open，但是window.open却会补浏览器屏掉，这时候该怎么办？<br/><br/>我想到form和target属性，于是有了下面代码的产生。 <img src="http://www.kekecn.com/blog/images/smilies/Face_02.gif" border="0" style="margin:0px 0px -2px 0px" alt=""/><br/><br/><div class="UBBPanel"><div class="UBBTitle"><img src="http://www.kekecn.com/blog/images/html.gif" style="margin:0px 2px -3px 0px"> HTML代码</div><div class="UBBContent"><TEXTAREA rows="8" id="temp52913">
<script language=&#34;javascript&#34;>
<!--
function formaction()
{
	sel&#101;ctObj = document.getElementById(&#34;friendlink&#34;);
	//alert();
	if(sel&#101;ctObj.options[sel&#101;ctObj.sel&#101;ctedIndex].value!=''){
	//alert(sel&#101;ctObj.options[sel&#101;ctObj.sel&#101;ctedIndex].value);
	//window.open(sel&#101;ctObj.options[sel&#101;ctObj.sel&#101;ctedIndex].value);
	document.getElementById(&#34;friendlinkform&#34;).action=sel&#101;ctObj.options[sel&#101;ctObj.sel&#101;ctedIndex].value;
	friendlinkform.submit();
	}
}
-->
</script>
<form action=&#34;&#34; target=&#34;_blank&#34; id=&#34;friendlinkform&#34; name=&#34;friendlinkform&#34;>
</form>
 <sel&#101;ct name=&#34;friendlink&#34; onChange=&#34;javascript:formaction();&#34;>
<option>==友情链接==</option>
<option value=&#34;<a href="http://www.kekecn.com" target="_blank" rel="external">http://www.kekecn.com</a>&#34;><a href="http://www.kekecn.com" target="_blank">KeKe</a></option>
 </sel&#101;ct>
</TEXTAREA><br/><INPUT onclick="runEx('temp52913')"  type="button" class="userbutton" value="运行此代码"/> <INPUT onclick="doCopy('temp52913')"  type="button" class="userbutton" value="复制此代码"/> <INPUT onclick="saveCode('temp52913')" type="button" class="userbutton" value="保存此代码"><br/> [Ctrl+A 全部选择 提示：你可先修改部分代码，再按运行]</div></div>]]></description>
		</item>
		
			<item>
			<link>http://www.kekecn.com/blog/article.asp?id=886</link>
			<title><![CDATA[个人全职承接网站程序外包服务]]></title>
			<author>kekecn@gmail.com(红心男孩)</author>
			<category><![CDATA[Other]]></category>
			<pubDate>Sun,08 Mar 2009 13:53:30 +0800</pubDate>
			<guid>http://www.kekecn.com/blog/default.asp?id=886</guid>
		<description><![CDATA[六年网站开发工作经验，全职承接网站程序外包服务，价格从优。有合作意向的网络公司或者朋友联系详谈。。<br/><br/>PS：希望建立长期合作的关系。<br/><br/>QQ：4315764<br/><br/><br/>部分作品：<br/><br/>服务IT网&nbsp;&nbsp;<a href="http://www.fwit.com.cn" target="_blank" rel="external">http://www.fwit.com.cn</a><br/>简介：为IT企业服务的一个综合性门户网站，我主要负责这站的项目管理和技术支持。<br/><br/>易安恢复&nbsp;&nbsp;<a href="http://www.huifu123.com" target="_blank" rel="external">http://www.huifu123.com</a><br/>简介：数据恢复信息网站，整站静态生成；代码都为手工KeyIn，都为原创。<br/><br/>创乐模型网&nbsp;&nbsp;<a href="http://clmodel.two.16admin.com" target="_blank" rel="external">http://clmodel.two.16admin.com</a><br/>简介：用“科讯CMS系统”刚做的雕塑模型网，现在还在测试当中。<br/><br/>2+1G&nbsp;&nbsp;<a href="http://www.e1g.com.cn" target="_blank" rel="external">http://www.e1g.com.cn</a><br/>简介：手机方面的在线商城网站。<br/><br/>111k商城&nbsp;&nbsp;<a href="http://www.111k.com.cn" target="_blank" rel="external">http://www.111k.com.cn</a><br/>简介：电脑配件方面的在线商城网站。测试当中<br/><br/>企业网站<br/>德尔地板：<a href="http://www.der.com.cn" target="_blank" rel="external">http://www.der.com.cn</a><br/>Kent：<a href="http://www.kentad.com" target="_blank" rel="external">http://www.kentad.com</a><br/>菲哩服饰：<a href="http://www.feili8.com" target="_blank" rel="external">http://www.feili8.com</a><br/>深圳德润：<a href="http://www.szderun.com" target="_blank" rel="external">http://www.szderun.com</a><br/>广州爱信：<a href="http://www.acendigi.com" target="_blank" rel="external">http://www.acendigi.com</a><br/>安防：<a href="http://www.ch3s.com" target="_blank" rel="external">http://www.ch3s.com</a><br/>广东美安：<a href="http://www.ma008.com" target="_blank" rel="external">http://www.ma008.com</a><br/>东莞万山礼品：<a href="http://www.wanshen.net/" target="_blank" rel="external">http://www.wanshen.net/</a><br/>………………………]]></description>
		</item>
		
			<item>
			<link>http://www.kekecn.com/blog/article.asp?id=885</link>
			<title><![CDATA[PHP中URL分析函数：parse_url]]></title>
			<author>kekecn@gmail.com(红心男孩)</author>
			<category><![CDATA[Asp&amp;PHP]]></category>
			<pubDate>Fri,06 Mar 2009 09:18:08 +0800</pubDate>
			<guid>http://www.kekecn.com/blog/default.asp?id=885</guid>
		<description><![CDATA[有这样一个地址：$url = &#39;<a href="http://www.kekecn.com:8080/tech/view.php?id=111" target="_blank" rel="external">http://www.kekecn.com:8080/tech/view.php?id=111</a>&amp;sortid=222#mark=333&#39;;<br/>分析这个URL，可以使用parse_url<br/>执行如下代码：<br/><div class="UBBPanel codePanel"><div class="UBBTitle"><a onClick="copycode(code16819);" style="float:right;cursor: pointer;font-weight: normal; font-style: normal">复制内容到剪贴板</a><img src="http://www.kekecn.com/blog/images/code.gif" style="margin:0px 2px -3px 0px;" alt="程序代码"/> 程序代码</div><div class="UBBContent" id=code16819><br/>$url = &#39;<a href="http://www.kekecn.com:8080/tech/download.asp?id=111" target="_blank" rel="external">http://www.kekecn.com:8080/tech/download.asp?id=111</a>&amp;sortid=222#mark=333&#39;;<br/>$url_info=parse_url($url);<br/>echo $url_info;<br/></div></div><br/><br/>返回一个数组，详细的是：<br/>Array ([scheme] =&gt; http [host] =&gt; www.kekecn.com [port] =&gt; 8080 [path] =&gt; /tech/view.php [query] =&gt; id=111&amp;sortid=222 [fragment] =&gt; mark=333)<br/><br/>执行如下代码：<br/><div class="UBBPanel codePanel"><div class="UBBTitle"><a onClick="copycode(code72621);" style="float:right;cursor: pointer;font-weight: normal; font-style: normal">复制内容到剪贴板</a><img src="http://www.kekecn.com/blog/images/code.gif" style="margin:0px 2px -3px 0px;" alt="程序代码"/> 程序代码</div><div class="UBBContent" id=code72621><br/>echo $url_info[&#39;host&#39;].&#39;&lt;hr size=&#34;1&#34; /&gt;&#39;;<br/>echo $url_info[&#39;port&#39;].&#39;&lt;hr size=&#34;1&#34; /&gt;&#39;;<br/>echo $url_info[&#39;path&#39;].&#39;&lt;hr size=&#34;1&#34; /&gt;&#39;;<br/>echo $url_info[&#39;query&#39;].&#39;&lt;hr size=&#34;1&#34; /&gt;&#39;;<br/>echo $url_info[&#39;fragment&#39;];<br/></div></div><br/><br/>返回：<br/><div class="UBBPanel codePanel"><div class="UBBTitle"><a onClick="copycode(code31772);" style="float:right;cursor: pointer;font-weight: normal; font-style: normal">复制内容到剪贴板</a><img src="http://www.kekecn.com/blog/images/code.gif" style="margin:0px 2px -3px 0px;" alt="程序代码"/> 程序代码</div><div class="UBBContent" id=code31772><br/>www.kekecn.com<br/>--------------------------------------------------------------------------------<br/>8080<br/>--------------------------------------------------------------------------------<br/>/tech/view.php<br/>--------------------------------------------------------------------------------<br/>id=111&amp;sortid=222<br/>--------------------------------------------------------------------------------<br/>mark=333<br/></div></div><br/><br/><br/>实例：<br/><br/>从数据中读出的 值是<br/><a target="_blank" href="http://www.kekecn.com/newhouse/domicile_view.php?proid=7031323034363838393433313939&amp;&amp;type=1" rel="external">http://www.kekecn.com/newhouse/domicile_view.php?proid=7031323034363838393433313939&amp;&amp;type=1</a><br/><br/>现在要获得proid的值 7031323034363838393433313939&nbsp;&nbsp;和 type的值 1<br/><br/><div class="UBBPanel codePanel"><div class="UBBTitle"><a onClick="copycode(code27759);" style="float:right;cursor: pointer;font-weight: normal; font-style: normal">复制内容到剪贴板</a><img src="http://www.kekecn.com/blog/images/code.gif" style="margin:0px 2px -3px 0px;" alt="程序代码"/> 程序代码</div><div class="UBBContent" id=code27759><br/>&lt;?php<br/>$str =&#39;<a href="http://www.kekecn.com/newhouse/domicile_view.php?proid=7031323034363838393433313939" target="_blank" rel="external">http://www.kekecn.com/newhouse/domicile_view.php?proid=7031323034363838393433313939</a>&amp;&amp;type=1&#39;;<br/>$query = parse_url($str);<br/>preg_match_all(&#34;/=(\d+)/i&#34;,$query[&#39;query&#39;], $match);<br/>print_r($match);<br/>?&gt;<br/></div></div>]]></description>
		</item>
		
</channel>
</rss>
