Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Browse files

Add some words about SDWebImageRefreshCached in README

  • Loading branch information...
commit f74780484330c3f41893185112d2cd915521fc07 1 parent b1f1c08
@rs authored
Showing with 13 additions and 0 deletions.
  1. +13 −0
@@ -193,6 +193,19 @@ The following article gives a way to workaround this issue:
+### Handle image refresh
+SDWebImage does very aggressive caching by default. It ignores all kind of caching control header returned by the HTTP server and cache the returned images with no time restriction. It implies your images URLs are static URLs pointing to images that never change. If the pointed image happen to change, some parts of the URL should change accordingly.
+If you don't control the image server you're using, you may not be able to change the URL when its content is updated. This is the case for Facebook avatar URLs for instance. In such case, you may use the `SDWebImageRefreshCached` flag. This will slightly degrade the performance but will respect the HTTP caching control headers:
+``` objective-c
+[imageView setImageWithURL:[NSURL URLWithString:@""]
+ placeholderImage:[UIImage imageNamed:@"avatar-placeholder.png"]
+ options:SDWebImageRefreshCached];
Please sign in to comment.
Something went wrong with that request. Please try again.