Closed (fixed)
Project:
ImageCache
Version:
6.x-2.0-beta9
Component:
Miscellaneous
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
26 Aug 2009 at 08:50 UTC
Updated:
24 Oct 2009 at 21:30 UTC
Hi!
Currently when I hover the mouse over an image served by imagecache, the path looks something like this:
http://domain.com/sites/default/files/imagecache/reg/photos/DSC_7681.JPG
I would like to make this URL more "pretty", something like http://domain.com/images/large/DSC_7681.JPG
Is this possible using mod_rewrite and the .htaccess file?
Thanks in advance for any help!
Bence
Comments
Comment #1
Mike_Waters commentedI am also interested in this. It could be done using mod_rewrite, but that would likely be a configuration nightmare. Or perhaps custom_url_rewrite_outbound/inbound with some rules (e.g. 'rewrite all jpg paths to /') or a db table of 1-to-1 url mappings (e.g. 'sites/all/thumbnail/bence.jpg --> /bence.jpg').
Comment #2
drewish commentedi think Mike_Waters has the general idea here. Use custom_url_rewrite_outbound() to create shorter URLs then use mod_rewrite to expand them back out.