Example #1
0
        public static ConfigEntity.WebSiteZWCE SiteConfig(string sHost)
        {
            ConfigEntity.WebSiteZWCE siteConfig = new ConfigEntity.WebSiteZWCE();

            siteConfig = GetConfigFromCache(sHost);

            return siteConfig;
        }
Example #2
0
        private static ConfigEntity.WebSiteZWCE GetConfigFromCache(string sHost)
        {
            ConfigEntity.WebSiteZWCE siteConfig = new ConfigEntity.WebSiteZWCE();

            if (System.Web.HttpContext.Current.Cache[sHost] != null)
            {
                Dictionary<string, ConfigEntity.WebSiteZWCE> dict = (Dictionary<string, ConfigEntity.WebSiteZWCE>)System.Web.HttpContext.Current.Cache[sHost];
                if (dict.ContainsKey(sHost))
                {
                    siteConfig = dict[sHost];

                }
            }

            return siteConfig;
        }