IIS设置防盗链设置,服务器设置。

http://www.helicontech.com/download-isapi_rewrite3.htm

这个是 isapi_rewrite

 

 

我是这样设置的:

 

首先下载一个安装包:是discuz论坛的写静态 文件。

 

http://www.discuz.net/attachment.php?aid=124274 

要是防盗链的话,就打开这个页面进行下载:

http://faq.comsenz.com/usersguide

 

然后根据其说明进行设置,然后

 

RewriteCond Host: (.+)

RewriteCond Referer: (?!http://(?:friend\.iielts\.cn|www\.iielts\.cn|image\.baidu\.com|www\.baidu\.com|www\.google\.com|images\.google\.com|www\.google\.cn|images\.google\.cn)).+

RewriteRule .*\.(?:pdf|doc|exe|rar|gif|jpg|png|) /block.gif [I,O]

 

这段代码加在 httpd.ini 文件里就可以了。

 

 

友情链接 : 遨游官方论坛:http://www.7v7.cn/?fromuid=177

原文地址:https://www.cnblogs.com/binlunia/p/11267768.html