This question seems simple to me though I can't seem to get it to work.
I'm trying to do a simple rewrite for all requests except defined image types.
Three very important clarifications:
This is being done with the .htaccess file in the image directory that accessed from a browser is located at example.com/images/ so the .htaccess file is located at public_html/images/.htaccess locally.
This solution needs to play nicely with the awesome help I received from other people at this question: Apache Rewrite: image directory based on HTTP host
I'm using shared hosting, not VPS or dedicated so my access is limited; I know this isn't going to be complicated anyway.
I've tried the following (along with modifications of it) without success:
public_html/images/.htaccess
RewriteEngine on
RewriteRule !.(gif|jpg|png)$ index.php?q=$1 [L]
I think I'm probably just missing something simple here.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…