Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/.htaccess/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php URL重写错误500_Php_.htaccess - Fatal编程技术网

Php URL重写错误500

Php URL重写错误500,php,.htaccess,Php,.htaccess,我是重写url的初学者。我试着做简单的重写,但结果很糟糕。我不知道为什么。寻找答案,但什么也没找到 我遇到的错误: 500内部服务器错误|此外,尝试使用ErrorDocument处理请求时遇到404 Not Found错误 我的htaccess文件位于/admin/.htaccess中 我在/.htaccess中还有另一个代码:Options-index 感谢您的帮助尝试在[NC,L]中不留空格: # Rewriting URLs RewriteEngine On RewriteRule ^c

我是重写url的初学者。我试着做简单的重写,但结果很糟糕。我不知道为什么。寻找答案,但什么也没找到

我遇到的错误:

500内部服务器错误|此外,尝试使用ErrorDocument处理请求时遇到404 Not Found错误

我的htaccess文件位于/admin/.htaccess中 我在/.htaccess中还有另一个代码:Options-index


感谢您的帮助

尝试在[NC,L]中不留空格:

# Rewriting URLs
RewriteEngine On

RewriteRule ^custom dashboard.php [NC,L]

错误日志怎么说?找不到我删除了空间,还有一个错误。在此服务器上找不到请求的URL/admin/custom。此外,尝试使用ErrorDocument处理请求时遇到404 Not Found错误。
# Rewriting URLs
RewriteEngine On

RewriteRule ^custom dashboard.php [NC,L]