Making photos cachable in secure environments
If your Profiles deployment is configured to prevent profile data from being accessible to readers, you can opt to make just user photos cachable.
Before you begin
Procedure
Define a rule in the IBM® HTTP
Server to explicitly set the caching headers of profile photos by
completing the following steps:
- Using a text editor, open the httpd.conf file,
which is the IBM® HTTP Server
configuration file. The file is stored in the following directory
by default:
- AIX®: /usr/IBM/HTTPServer/conf
- Linux™: /opt/IBM/HTTPServer/conf
- Microsoft™ Windows™: C:\IBM\HTTPServer\conf
- Add the following block of code to the httpd.conf file:
<LocationMatch /*/profiles/photo.do > <IfModule mod_headers.c> Header set Pragma "" Header set Cache-Control "max-age=21600,s-maxage=21600,public" </IfModule> </LocationMatch>
- Save and close the configuration file.
- Restart the IBM® HTTP Server.