-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Set cache-control headers for caching #10
Comments
Are you thinking just setting the max-age, or do you wish to support the $cache_time = do_filter( 'wpcom_vip_ad_busters_cache_time', false );
if( false !== $cache_time )
header( 'Cache-Control: max-age='. int( $cache_time ) ); |
We should always set a cache expiration time, but i'm always happy to add filters or actions. I don't have a preference for the default cache time, so whatever seems sensible to you. :) Let's go for both |
I don't think a filter is all that helpful here. Is there a particular use
|
I can't think of a reason for filtering, since, as you say, the files do not change that often. $age = 60*60*24*1;
header( 'Cache-Control: max-age=' . $age );
header( 'Expires: ' . gmdate( "D, d M Y H:i:s", time() + $age ) . ' GMT' ); |
No description provided.
The text was updated successfully, but these errors were encountered: