.htaccess在本地工作,但在GoDaddy上提供404

.htaccess在本地工作,但在GoDaddy上提供404,.htaccess,http-status-code-404,.htaccess,Http Status Code 404,我的.htaccess文件中有以下代码: Options +FollowSymLinks -MultiViews -Indexes RewriteEngine On RewriteRule ^(design|JS|css|images|remoteLibraries|remoteLibraries/xAJAX/xajax_js/)($|/) - [L] RewriteRule ^([a-zA-Z_]+)$ index.php?action=$1 RewriteRule ^([a-zA-Z_]+

我的.htaccess文件中有以下代码:

Options +FollowSymLinks -MultiViews -Indexes
RewriteEngine On

RewriteRule ^(design|JS|css|images|remoteLibraries|remoteLibraries/xAJAX/xajax_js/)($|/) - [L]
RewriteRule ^([a-zA-Z_]+)$ index.php?action=$1
RewriteRule ^([a-zA-Z_]+)/([a-z_A-Z]+)$ index.php?action=$1&tip=$2
它在我的本地Apache服务器上运行良好,但当将其上载到GoDaddy时,我得到的是404NotFound错误

有什么想法吗?

1)我建议你设置一个重写库,通常只是

RewriteBase /
这有助于标准化重写在何处生效,因为本地服务器和远程服务器之间的目录结构可能不同

2) 我还建议,每当出现意外的重写行为时,设置

ErrorDocument 404 default
这样Go Daddy 404页面也不会被重定向