1
0
mirror of https://github.com/owncloudarchive/contacts.git synced 2024-11-29 11:24:11 +01:00

OC_Response: add setExpiresHeader function

This commit is contained in:
Bart Visscher 2012-02-12 20:38:28 +01:00
parent 76b1f19e88
commit 96ee0ceca3

View File

@ -27,9 +27,7 @@ OC_JSON::checkLoggedIn();
OC_Util::checkAppEnabled('contacts');
function getStandardImage(){
$date = new DateTime('now');
$date->add(new DateInterval('P10D'));
header('Expires: '.$date->format(DateTime::RFC2822));
OC_Response::setExpiresHeader('P10D');
OC_Response::enableCaching();
OC_Response::redirect(OC_Helper::imagePath('contacts', 'person.png'));
}