This is my htaccess file, and for some reason this rule: RewriteRule ^profile/([^/]+)$ ./profile.php?name=$1 doesn't allow dots in the link. It allows any other symbol, but not the dot (.). How can I fix this?
Options -MultiViews -Indexes
RewriteEngine On
RewriteCond %{HTTP:VIA} !^$ [OR]
RewriteCond %{HTTP:FORWARDED} !^$ [OR]
RewriteCond %{HTTP:USERAGENT_VIA} !^$ [OR]
RewriteCond %{HTTP:X_FORWARDED_FOR} !^$ [OR]
RewriteCond %{HTTP:PROXY_CONNECTION} !^$ [OR]
RewriteCond %{HTTP:XPROXY_CONNECTION} !^$ [OR]
RewriteCond %{HTTP:HTTP_PC_REMOTE_ADDR} !^$ [OR]
RewriteCond %{HTTP:HTTP_CLIENT_IP} !^$
RewriteRule ^(.*)$ - [F]
DirectorySlash On
ErrorDocument 404 /404.php
ErrorDocument 403 /404.php
ErrorDocument 502 /brb.php
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-l
RewriteCond %{REQUEST_URI} (.+)/$
RewriteCond %{THE_REQUEST} /profile\?name= [NC]
RewriteRule ^ - [L]
RewriteRule ^profile/([^/]+)$ ./profile.php?name=$1
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteRule ^([^/.]+)\.php - [F,L,R=404]
RewriteRule ^([^/.]+)$ $1.php [L]
On my website, users can register with any name (thus any character). But let's say I put my fictional name to be "Mr.BoogieMan.", the link to my profile should be www.website.com/profile/Mr.BoogieMan. But since the dot is in my name, htaccess won't let that go through.