TTL for fragment caching

5 views
Skip to first unread message

spariam

unread,
Apr 17, 2008, 6:19:37 PM4/17/08
to acts_as_cached
Is this possible with fragment caching using cache_fu? I've seen some
code sample for time-based expiration of fragment cache, but not using
cache_fu.

Thanks.

Chris Wanstrath

unread,
Apr 17, 2008, 6:37:30 PM4/17/08
to acts_as...@googlegroups.com
Yes,

<% cache(whatever, { :ttl => 1.day }) do %>
html
<% end %>

--
Chris Wanstrath
http://github.com/defunkt

spariam

unread,
Apr 18, 2008, 11:14:27 AM4/18/08
to acts_as_cached
Thanks, I had a suspicion it was that simple!

On Apr 17, 5:37 pm, "Chris Wanstrath" <ch...@ozmm.org> wrote:
> Yes,
>
> <% cache(whatever, { :ttl => 1.day }) do %>
> html
> <% end %>
>
Reply all
Reply to author
Forward
0 new messages