views:

16

answers:

1

I want all css, javascript, and image file requests, that are named like this "filename.12345.css" to be re-routed to "filename.css".

The ".12345" part will always be numbers and the length can be anywhere from 11 - 15 characters.

This directive seems to work OK but I want to make sure there is no error in my logic.

RewriteRule ^(.+)\.(.+)\.(js|css|jpg|gif|png)$ $1.$3

Any help would be greatly

+1  A: 

Extra periods can interfere.

RewriteRule ^(.+)\.([^.]+)\.(js|css|jpg|gif|png)$ $1.$3

or

RewriteRule ^(.+)\.(\d+)\.(js|css|jpg|gif|png)$ $1.$3
Ignacio Vazquez-Abrams
I knew there was something missing. Thanks!
Bill H