Partial Class Visitors_Policies
    Inherits CharterCMSPage


	Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        MyBase.SetTemplate(6)
        Dim _policyName As PolicyName

    If Not Page.IsPostBack Then
      'Response.AddCacheItemDependency(CacheKey.OutputCacheDurationKey)
            Dim d As DateTime = CachedControls.getExpireDate()

      If HttpContext.Current.Cache.Item("Template6") Is Nothing Then
        HttpContext.Current.Cache.Insert("Template6", DateTime.Now, Nothing, d, System.TimeSpan.Zero, System.Web.Caching.CacheItemPriority.NotRemovable, Nothing)
      End If

      Response.AddCacheItemDependency("Template6") 'CacheKey.OutputCacheDurationKey)

      If Application(Request.Url.LocalPath) Is Nothing Then
        Application.Add(Request.Url.LocalPath, "Template6")
      End If

      If Request.QueryString(QueryStringName.Policy) IsNot Nothing Then
        _policyName = CType(Request.QueryString(QueryStringName.Policy), PolicyName)
        ucCustomContent.ContentKey = String.Format("{0}:{1}", QueryStringName.Policy, _policyName.ToString())
        ucCustomContent.Visible = True
      Else
        ucCustomContent.ContentKey = Nothing
        ucCustomContent.Visible = False
      End If
    End If
	End Sub
End Class
