.htaccess 使用另一个url重写htaccess url时出错

.htaccess 使用另一个url重写htaccess url时出错,.htaccess,.htaccess,我正在尝试使用特定的变量和格式进行重定向。 以下是我想要的url的格式: https://example.com/1234/http%3A%2F%2F5external-link.com https://example.com/1234/http://external-link.com 我的htaccess设置如下 Options +FollowSymLinks -MultiViews RewriteEngine on RewriteBase / RewriteRule ^([0-9]+)/(

我正在尝试使用特定的变量和格式进行重定向。 以下是我想要的url的格式:

https://example.com/1234/http%3A%2F%2F5external-link.com
https://example.com/1234/http://external-link.com
我的htaccess设置如下

Options +FollowSymLinks -MultiViews
RewriteEngine on
RewriteBase /
RewriteRule ^([0-9]+)/(.*)$ index.php?id=$1&url=$2 [L,NE]

我缺少什么?

以前没有规则?只有基本设置。根据,它应该适用于这两个URL。同时向我们展示您的“仅基本设置”,展示完整的.htaccess/重写配置。上面的htaccess代码是最新的,我只有这些。我已经测试过了,但当我在网站上有代码时,我得到了404错误代码。