Wordpress URL Rewriting Ignores Existing Files
I have wordpress installed at the web root directory of a server. I also have a file called test.php in the same directory that is not at all related or connected to wordpress (atleast not by any code within the test.php file). if i go to http://myurl.com/test.php i get my theme's styling and the wordpress error message for when it can't find a post at that particular url.
Is there a UI element in the Admin da开发者_JS百科shboard that allows you to change this behavior (I can't find one, but I wouldn't be surprised if I've overlooked it) or do I have to edit the modrewrite rules myself? Thanks.
This is the .htaccess RewriteRule
generated by a WordPress install I have. Note the RewriteCond
s:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
!-f
means if a file at that path does not exist. !-d
means if a directory at that path does not exist.
Even though you say your .htaccess
has the correct RewriteCond
, it is most likely misconfigured, or perhaps there are conflicting statements?
Can you post the entire contents of your .htaccess
?
精彩评论