我目前处理服务器状态并且一切正常,但我无法获取我的.htaccess文件以输出像ark.kazuto.de/312142448.png这样的网址,因为它抓住了知识产权。
RewriteEngine On
RewriteCond %{THE_REQUEST} \ /+status\.php\?ip=([^&\ ]+)
RewriteRule ^ /%1.png? [L,R]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([^/\.]+)\.png$ /status.php?ip=$1 [L,QSA]
有人能帮我快点吗?
答案 0 :(得分:0)
您可以使用此规则:
RewriteEngine On
RewriteCond %{THE_REQUEST} \ /+status\.php\?ip=([^&\s]+)
RewriteRule ^ /%1.png? [L,R]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.+?)\.png$ status.php?ip=$1 [L,QSA,NC]