source: products/vendor/Products.CacheSetup/current/Products/CacheSetup/skins/cache_setup/cache_policy_redirect.py @ 3296

Last change on this file since 3296 was 3296, checked in by fenix, 13 years ago

Load Products.CacheSetup?-1.2.1 into vendor/Products.CacheSetup?/current.

  • Property svn:eol-style set to native
File size: 447 bytes
Line 
1## Script (Python) "cache_policy_redirect"
2##bind container=container
3##bind context=context
4##bind namespace=
5##bind script=script
6##bind subpath=traverse_subpath
7##parameters=
8##title=Cache Policy Redirect
9from Products.CMFCore.utils import getToolByName
10
11camefrom = traverse_subpath[0]
12policy_id = traverse_subpath[1]
13ct = getToolByName(context, 'portal_cache_settings')
14
15return ct.setDisplayPolicy(policy_id, camefrom=camefrom, redirect=True)
Note: See TracBrowser for help on using the repository browser.