我正在尝试在Sitecore 8.1中启动并运行基本布局,并且我遇到了一个错误,我可以找到很少的信息.当试图查看任何页面(甚至是后端界面或从Sitecore Rocks连接)时,我收到消息"找不到会话ID管理器来管理当前请求的会话ID".
一些谷歌搜索表明,这与现成的会话提供商的一些问题有关,并建议将其交换出来以保持Mongo中的会话.Sitecore的文档提供了对共享和私有会话的描述.我试图实现这些但继续收到相同的错误.
这是我现在的代码:
APP_CONFIG /包含/ MongoSessionProvider.config
<?xml version="1.0"?>
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/">
<sitecore>
<tracking>
<sharedSessionState>
<providers>
<clear/>
<add name="mongo" type="Sitecore.SessionProvider.MongoDB.MongoSessionProvider, Sitecore.SessionProvider.MongoDB" connectionString="session" pollingInterval="2" compression="true" sessionType="shared"/>
</providers>
</sharedSessionState>
</tracking>
</sitecore>
</configuration>
Run Code Online (Sandbox Code Playgroud)
App_Config/Include/ConnectionStrings.config(摘录)
<add name="session" connectionString="mongodb://localhost/sharedsession" />
Run Code Online (Sandbox Code Playgroud)
Web.config(摘录)
<sessionState mode="Custom" cookieless="false" timeout="20" sessionIDManagerType="Sitecore.FXM.SessionManagement.ConditionalSessionIdManager" customProvider="mongo">
<providers>
<add name="mongo" type="Sitecore.SessionProvider.MongoDB.MongoSessionStateProvider, Sitecore.SessionProvider.MongoDB" sessionType="Standard" connectionStringName="session" pollingInterval="2" compression="true" />
<add name="mssql" type="Sitecore.SessionProvider.Sql.SqlSessionStateProvider, Sitecore.SessionProvider.Sql" sessionType="Standard" connectionStringName="session" pollingInterval="2" compression="true" />
</providers>
</sessionState>
Run Code Online (Sandbox Code Playgroud)
请注意,这是在我的本地开发机器上.我有蒙戈运行(并确认其Sitecore的连接),我用它创建Session和sharedsession数据库use session
和use sharedsession
,我的理解是在蒙戈创建数据块的方式.
我在这里错过了什么吗?或者错误是不是意味着我认为它意味着什么?
我有一个启用了分析的多站点解决方案.当用户访问其中一个站点时,分析引擎似乎将用户重定向到其他站点.
我在这里读到,这可能是由于Analytics.HostName
包含用户被重定向到的站点的主机引起的.但是,此设置为空.
以下是请求和响应标头:
我在我的网站ar-AE中添加了新语言,如果我想访问阿拉伯语网站,我会在网站网址后附加"ar-AE":
但我希望它只与/ ar一起使用
我怎么能用sitecore做到这一点?
我使用Sitecore的8.1版本,并试图创造Templates
,Fields
并Items
以编程方式(保证的情况下,项目的一些场景/模板不存在的),我想设置特定模板的字段shared
或unversioned
,但不能因为:
bool TemplateFieldItem.Shared
属性只有getter
方法(没有setter).
我的代码:
var icon = PageTemplate.AddField("Icon", "Data");
using (new EditContext(icon.InnerItem))
{
icon.Type = "Image";
icon.Sortorder = 3;
icon.Shared = false;
}
Run Code Online (Sandbox Code Playgroud)
所以我的问题是,只有在 icon.Shared = false;
和icon.Unversioned = false;
在早期版本的Sitecore中,字典项存在问题,如果我们有CD环境,有时Dictionary.dat文件可能无法在CD服务器上更新.
1)Sitecore 8仍然存在此问题吗?
2)如果是,为我的网站实现自定义词典项目的最佳方法是什么?
我使用副本集为Sitecore配置了MongoDB.我设置了密钥文件访问控制并添加了一个用户.但是我在创建连接字符串时遇到了问题.
让我们假设我的副本集名称rsHelloWorld
有几个mongod
实例:localhost:21017,localhost:21018,localhost:21019,localhost:21020,localhost:21021(arbitor)
username: mongo_admin
password: test@123
Run Code Online (Sandbox Code Playgroud)
Sitecore中的默认连接字符串是:
<add name="analytics" connectionString="mongodb://localhost/analytics" />
Run Code Online (Sandbox Code Playgroud)
如何使用副本集和身份验证为MongoDB数据库指定连接字符串?
我们遇到了一个问题,我们在基本模板上的项目级别启用了后备语言设置,以便它可以应用于我们的所有项目.虽然sitecore内容编辑器表明它正在运行,但它对我们大约90%的项目起作用,但对其他项目则没有.
将此放在此处给其他有此问题的人.我没有在Google上找到针对此问题的具体解决方案,并且很幸运能够解决这个问题.希望这也可以帮助其他人.
我们的设置是Sitecore 8.1与Habitat Asp.net MVC
我正在使用sitecore 8.1,并希望将sitecore的默认登录URL从http:// domain/sitecore/login更改为http:// domain/admin-login.我不想更改物理文件的结构,所以我只是在App_Config/sitecore.config中更新了以下设置
<site name="shell" ----- loginPage="/admin-login" ------/>
<site name="login" virtualFolder="/admin-login" physicalFolder="/sitecore/login" ------/>
现在我可以通过http:// domain/admin-login访问登录页面,但旧路径http:// domain/sitecore/login仍然存在可能是因为物理文件夹结构.
有什么想法吗 ?或者sitecore建议的最佳做法?
我正在使用Sitecore 8.1和GlassMapper来映射C#中的字段.我正在为开发的组件使用数据源.
我需要能够从我们当前所在的页面中获取一个字段.您知道如何在Sitecore中定义页面对象吗?
我正在CM和CD环境中部署我的网站,我使用solr进行搜索我按照Sitecore的所有说明从这个链接配置cm环境:
当我打开cm网站时,我收到错误说sitecore_web_index
未找到:
在上面的链接当我转到文件以启用或禁用Solr部分并单击"Excel电子表格".他们说禁用
Sitecore.ContentSearch.Solr.Index.Web.config:
有关此错误的任何想法?我应该在CM上保持web索引禁用吗?
我正在使用sitecore 8.1 update 2
我正在使用此代码来检索项目:
ISearchIndex SitecoreSearchIndex=ContentSearchManager.GetIndex("sitecore_" + Sitecore.Context.Database.Name + "_index");
using (var context = SitecoreSearchIndex.CreateSearchContext())
{
var culture = Sitecore.Context.Language.CultureInfo;
var predicate = PredicateBuilder.True<SearchResultItem>();
predicate = predicate.And(p => p.Paths.Contains(CommonTextFolderId));
predicate = predicate.And(p => p.TemplateId == CommonTextTemplateId);
predicate = predicate.And(p => p.Language == culture.Name);
var items = context.GetQueryable<SearchResultItem>().Where(predicate);
listCommonTexts = items.Select(p => SitecoreContext.Cast<CommonTextModel>(p.GetItem(), false, false)).ToList();
}
Run Code Online (Sandbox Code Playgroud) 我已从Sitecore 8.1升级到Sitecore 8.2.我有一个方法,我正在使用:
Sitecore.Context.PageMode.IsPageEditor
Run Code Online (Sandbox Code Playgroud)
为此,它给出了错误:
attempt by method METHOD_NAME to access method 'Sitecore.Context+PageMode.get_IsPageEditor()' failed.
Run Code Online (Sandbox Code Playgroud)
我错过了什么?
访问查看器中所做的任何更改都会自动反映在安全编辑器中,反之亦然.
我有以下与继续使用 Sitecore 作为我们的 WCM 解决方案并迁移到 Azure PaaS 解决方案上的 Sitecore 相关的查询。
1.继续使用 Sitecore 作为我们的 WCM 解决方案的优点是什么?
2.继续使用 Sitecore 作为我们的 WCM 解决方案有什么缺点?
3.迁移到 Sitecore on Azure PaaS 解决方案的优点是什么?
4.迁移到 Sitecore on Azure PaaS 解决方案的缺点是什么?
请帮助我理解这些。
谢谢
sitecore ×13
sitecore8.1 ×13
sitecore8 ×8
asp.net ×2
mongodb ×2
c# ×1
glass-mapper ×1
login ×1
multilingual ×1
session ×1
sitecore-fxm ×1
sitecore-mvc ×1
sitecore-xdb ×1
sitecore8.2 ×1
solr ×1