禁止未登录用户访问特定文件
# require login for media files
<IfModule mod_rewrite.c>
RewriteCond %{REQUEST_FILENAME} (jpeg|jpg|png|pdf)
RewriteCond %{HTTP_COOKIE} !wordpress_logged_in_([a-zA-Z0-9_]*) [NC]
RewriteRule .* - [F,L]
</IfModule>
# require login for media files
<IfModule mod_rewrite.c>
RewriteCond %{REQUEST_FILENAME} (jpeg|jpg|png|pdf)
RewriteCond %{HTTP_COOKIE} !wordpress_logged_in_([a-zA-Z0-9_]*) [NC]
RewriteRule .* - [F,L]
</IfModule>