I personally don't like needing to request for help, but editing .htaccess is just one of individuals things in existence which i cannot and won't ever wrap my mind around. I have been only at that for several weeks learning, and I have got nowhere. I finally admit defeat and are available seeking help!

I've got a directory:-

http://example.com/images/blog/year/month/anyfilename.jpg

Which I'd like, whether it's possible. To continually appear as:-

http://example.com/pix/anyfilename.jpg

I'd then still upload files within the correct year/month sites, which may simply be visible in my experience. Externally to site visitors, they'd begin to see the latter url when they seen the look (I'm able to take proper care of parsing the hyperlinks within the PHP pages to complement the rewritten "virtual" directory, myself to ensure that will not be an issue).

The occasions I have compare to getting it working, the pictures were no more visible, making sense, however i thought the purpose of having the ability to rewrite URL's ended up being to avoid needing to move files too?

I've RewriteEngine on, and Options +FollowSymlinks and that i know it's all regulated setup properly as other rules and redirects work. It is simply this that does not wish to play.

I've no good examples to exhibit when i don't have any good examples that actually work. I have looked everywhere, compare for an answer but never anything close enough as to the I am requiring, to really work with me. I am from ideas.

Assist me to Obi-Wan Overflow, you are my hope.

You cannot do what you're trying related to just mod-rewrite. The issue is you've multiple places where the file could live as well as your rewrite rule does not accept any type of input of how to locate it. You could do this something similar to http://www.example.com/pix-month-year/anyfilename.jpg. Mod-rewrite is not a scripting language.

Alternatively, you can produce a PHP script that you simply pass inside a file title, also it could sort through the look sites until it finds a match, and go through the look data towards the browser. (Make sure to account for the similar filename in multiple folders.)

Your mod_rewrite would just be something similar to this.

RewriteRule ^pix/(.*)$ find-pix.php?filename=$1