vendredi 24 juillet 2020

HTAccess rewrite rule ignored when using encoded url as a parameter

I have the following rule in my htaccess file which works fine except when the parameter is an encoded url

RewriteRule ^data/(.+)$ ?dataId=$1 [L]

If I pass an encoded URL like this the rule is ignored

https://example.com/data/https%3A%2F%2FsomeOtherUrl.com

It looks like %2F is causing this rule to be ignored. Any idea on how to handle this?

Thanks

EDI: BTW this URL works fine. Only the htaccess redirection doesn't work

https://example.com/?dataId=https%3A%2F%2FsomeOtherUrl.com




Aucun commentaire:

Enregistrer un commentaire