Question

Comment créer une RewriteRule apache qui capture toute URL de requête se terminant par .xml, supprime le fichier .xml et la transmet à un script spécifique?

http://www.example.com/document.xml, becomes http://www.example.com/document passed to script.php
Était-ce utile?

La solution

Cela devrait faire l'affaire, je crois.

RewriteRule ^(.+)\.xml$ script.php?path=$1
Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top