那位大虾能给小弟讲解一下防盗链的知识?

来源:百度知道 编辑:UC知道 时间:2024/05/12 09:48:01

在网页中加入防盗键代码,或服务器装上防盗键系统。
asp下载防盗链代码
在下载的页面头部做了如下代码,相关代码如下:
<%
From_url = Cstr(Request.ServerVariables("HTTP_REFERER"))
Serv_url = Cstr(Request.ServerVariables("SERVER_NAME"))
if mid(From_url,8,len(Serv_url)) <> Serv_url and mid(From_url,8,len(Serv_url))<>"net235.com" and mid(From_url,8,len(Serv_url))<>"xz.net235.com" then
response.write "您下载的软件来自..,请直接从主页下载,谢谢<br>" '防止盗链
response.write "<a href=http://xz.net235.com>....
http://www.hnlanling.com/vbbs</a>" '防止盗链
response.end
end if
%>