首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >找不到支持服务CMS.Helpers.ICurrentCookieLevelProvider的组件

问找不到支持服务CMS.Helpers.ICurrentCookieLevelProvider的组件
EN

Stack Overflow用户
提问于 2020-04-30 18:59:53
回答 1查看 66关注 0票数 0

嗨,我有一个kentico 11网站。当我尝试托管主机并从IIS本地运行它时,我收到以下错误

代码语言:javascript
复制
Server Error in '/' Application.
No component for supporting the service CMS.Helpers.ICurrentCookieLevelProvider was found
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: Castle.MicroKernel.ComponentNotFoundException: No component for supporting the service CMS.Helpers.ICurrentCookieLevelProvider was found

Source Error:


Line 16:     protected override void OnPreRender(EventArgs e)
Line 17:     {
Line 18:         base.OnPreRender(e);
Line 19: 
Line 20:         lblText.Text = "The web site doesn't contain any content. Sign in to <a href=\"" + ResolveUrl("~/Admin/cmsadministration.aspx") + "\">administration</a> and edit the content.";

Source File: \CMS\Default.aspx.cs    Line: 18

Stack Trace:


[ComponentNotFoundException: No component for supporting the service CMS.Helpers.ICurrentCookieLevelProvider was found]
   Castle.MicroKernel.DefaultKernel.Castle.MicroKernel.IKernelInternal.Resolve(Type service, Arguments arguments, IReleasePolicy policy, Boolean ignoreParentContext) +144
   Castle.MicroKernel.DefaultKernel.Resolve(Type service, Arguments arguments) +40
   Castle.Windsor.WindsorContainer.Resolve() +69
   CMS.Core.IoCContainer.Resolve() +93

[ServiceResolutionException: Resolution of 'CMS.Helpers.ICurrentCookieLevelProvider' failed with the following error: No component for supporting the service CMS.Helpers.ICurrentCookieLevelProvider was found]
   CMS.Core.IoCContainer.Resolve() +262
   CMS.Helpers.CookieHelper.IsCookieAllowedInternal(String name) +38
   CMS.Helpers.CookieHelper.GetValueInternal(String name, Boolean useDefaultValue, Boolean allowSensitiveData) +397
   CMS.DocumentEngine.DocumentContext.GetCurrentStylesheet(PageInfo pageInfo) +87
   CMS.UIControls.DocumentBase.get_CurrentStylesheet() +31
   CMS.UIControls.DocumentBase.SetCSS() +21
   CMS.UIControls.DocumentBase.PreRender() +44
   _Default.OnPreRender(EventArgs e) in \CMS\Default.aspx.cs:18
   System.Web.UI.Control.PreRenderRecursiveInternal() +132
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +4005

任何帮助都是非常有价值的。

EN

回答 1

Stack Overflow用户

发布于 2020-05-01 00:23:35

看起来有些CMS库可能丢失了。你是如何设置网站的:你是安装了Kentico,还是得到了代码和数据库备份?在Visual Studio中检查CMS项目中缺少的引用,清除,重新生成,然后重试。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/61521857

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档