如何合并两个htaccess文件——第一个用于用户名,第二个用于隐藏php扩展名


how to merge two htaccess files the first one is for the username and the second to hide php extension

我想合并这个.htaccess文件

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /profile.php?username=$1

用这个

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^'.]+)$ $1.php [NC]

它们都在根目录中

 RewriteEngine On
 RewriteCond %{REQUEST_FILENAME} !-f
 RewriteCond %{REQUEST_FILENAME} !-d
 RewriteRule ^(.*)$ /profile.php?username=$1
 RewriteRule ^([^'.]+)$ $1.php [NC]