location ^~ /uploads/ {//图片文件路径
valid_referers blocked www.baidu.com;//允许访问的域名
if ($invalid_referer) {
#rewrite ^/ http://www.hugwww.com/daolian.gif;
return 403;
}
expires 10d;
}