case and minuscule differences in the URL

Asked

Viewed 797 times

1

on my page, I have several images and the form that this writing on the path has uppercase and minuscule, for example, <img src="imagens/ImagemSistemaDepartamento.JPG">

needed that somehow .htacess read my code and independent uppercase and minuscule, find the image because it exists in the directory.

thank you.

  • 1

    It would be better to fix the names. Besides being more portable, the application will be conceptually correct. Nothing more than a search & replace well done don’t solve.

  • I agree with @Bacco. But don’t have a setting that allows . htacess to ignore ?

2 answers

2

  • 1

    It’s a solution to the problem. It is worth noting that there is a drop in performance, which can make a difference in heavier/accessed applications, because Apache has to scan the directory to find candidates for the URL, if it is not identical to the name of the desired resource. But as what the author asks is this, +1 in the answer.

0

You could do it this way:

<IfModule mod_rewrite.c>

RewriteEngine On
RewriteRule ^(.*)$ $1 [NC]

</IfModule>

Browser other questions tagged

You are not signed in. Login or sign up in order to post.