我的.htaccess错误地重定向到多次错误, 我试图重定向所有www。非www的流量,但同时删除文件扩展名,.php,.html,etx。
RewriteEngine On
RewriteCond %{HTTPS} off [OR]
RewriteCond %{HTTP_HOST} ^www\. [NC]
RewriteCond %{HTTP_HOST} ^(?:www\.)?(.+)$ [NC]
RewriteRule ^ https://%1%{REQUEST_URI} [L,NE,R=301]
#remove php file extension-e.g. https://example.com/file.php will become https://example.com/file
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}\.php -f
RewriteRule ^(.*)$ $1.php [NC,L]
它与我的表情有冲突吗?