On Jan 31, 2009, at 5:34 AM, Sumedh wrote:
> But the existing code references all images directly... :(
>
> /images/abc.gif and so on...
>
> I can refactor JS and CSS file references relatively easily...but
> refactoring references to all image files will be a little
> cumbersome... :|
>
> Are there any shortcuts so that I wouldn't need to do it? I couldnt
> think of any...
>
> Simplest shortcut will be of course to cache the content only for a
> few hours...and not many days...so that problem is not huge when files
> get updated...and get some benefit at least for a given browser
> session...

  1) short cache periods - you've touched on that
  2) version the filenames.  abc-1.gif and then abc-2.gif. plays hell  
with source control.
  3) write a custom image_tag() helper that applies a version number  
to the resource.  It could simply be a global revision/release number  
or it could be the mtime for the specific resource.  For example:  
abc.gif?12345678

--
Jacob Coby







--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"symfony users" group.
To post to this group, send email to symfony-users@googlegroups.com
To unsubscribe from this group, send email to 
symfony-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/symfony-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to