sitecore7

Sitecore Solr Search Score Value

时光总嘲笑我的痴心妄想 提交于 2019-12-02 12:20:38
I am trying to get the score value for each returned result item but the problem is all items returned the same score value. I am using sitecore 7.2 site which was upgraded from sitecore 6.6. I am using solr version 4.10.2-0 The following is the code that I am using: var contentPredicate = PredicateBuilder.True<customSearchResultItem>(); contentPredicate = contentPredicate.And(p => p.Content.Matches(SearchKey.Boost(1.0f))); IQueryable<SearchResultItem> query = context.GetQueryable<customSearchResultItem>().Where(contentPredicate); var hits = query.GetResults().Hits; foreach (var item in hits)

How to generate custom unique ID

一世执手 提交于 2019-12-02 04:44:22
问题 We are using Sitecore 7.2 with multi-site implementation. The actual data is shared between multisite, hence it's been stored in common Global Item folder. We are facing a problem generating aunique ID on URL. I had a good search but could not find any solution except to use Sitecore Item ID. This is what we want: domain/players/player_id e.g. domain/players/1234 where 1234 is uniquely generated ID. Could someone please suggest if this is possible? 回答1: Every page that is managed in Sitecore

How to generate custom unique ID

北慕城南 提交于 2019-12-01 23:33:32
We are using Sitecore 7.2 with multi-site implementation. The actual data is shared between multisite, hence it's been stored in common Global Item folder. We are facing a problem generating aunique ID on URL. I had a good search but could not find any solution except to use Sitecore Item ID. This is what we want: domain/players/player_id e.g. domain/players/1234 where 1234 is uniquely generated ID. Could someone please suggest if this is possible? Every page that is managed in Sitecore is a Sitecore Item. As such, you should be able to just navigate to the name of the player item. If you were

How do I get the value of a WFFM field as a tag and output it in a Sitecore DMS report?

佐手、 提交于 2019-12-01 20:52:16
If I create a Web Forms For Marketers form with Analytics enabled I can choose to add each field as a tag to a Visitor. I can't see how to configure which tag they should be added to, or even what the tag is called by default (I'm assuming a tag with the field name is created). I'd also like to know how to retrieve the tag data in a visit report (i.e. the one you'd get if you double clicked on a form submission in the Form Reports dialogue). I can see how to access plenty of inbuilt tags, but I can't find out how to fill these specifically from the form, and I cant see any fields in the report

How to link a droplink to a Treelist in Sitecore

吃可爱长大的小学妹 提交于 2019-12-01 11:16:47
I'm trying to figure out how I can link a Droplink to the selected items in a Treelist . I have a field Theme , which is the Treelist , and a field MasterTheme , which is the Droplink . I should be able to select a master-theme in the Droplink , which is filled with the selected data from the Treelist . I'm pretty new to Sitecore, and I'm not familiar with Custom classes. Kevin Brechbühl You can use the getLookupSourceItems -pipeline for this. With a Droplink you can specify a Sitecore query as source. And with the getLookupSourceItems you can change the source at runtime. The following

How to link a droplink to a Treelist in Sitecore

我的未来我决定 提交于 2019-12-01 09:59:15
问题 I'm trying to figure out how I can link a Droplink to the selected items in a Treelist . I have a field Theme , which is the Treelist , and a field MasterTheme , which is the Droplink . I should be able to select a master-theme in the Droplink , which is filled with the selected data from the Treelist . I'm pretty new to Sitecore, and I'm not familiar with Custom classes. 回答1: You can use the getLookupSourceItems -pipeline for this. With a Droplink you can specify a Sitecore query as source.

How do I bucket Sitecore items on something other than their creation date?

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-01 08:04:26
I'm using Sitecore with DMS (Sitecore 7.2), and I'm setting up various controls on my layouts to pull content from different folders based on the users profile card. I'd like those folders to be "bucket" folders, since there'll be one folder for each profile card, and it'll be a bit unpleasant for authors to have to manually update all of these folders every time a new profile card is added. The " Developers Guide to Item Buckets and Search " says: by default, the items are organized according to the date and time of when the item was created, but this can be configured to use different

Get Item in all languages in which it has a version

五迷三道 提交于 2019-12-01 04:41:10
Say we have an Item Product(which has versions in en, jp, zh and 0 versions in ru). How can I get this item in en, jp and zh and not in ru. I tried the below code. Item tempItem = Sitecore.Context.Database.GetItem(tempID); foreach (var itemLanguage in tempItem.Languages) { //Do Something } Here tempItem.Languages is returning all four languages where I was expecting only three as ru does not have versions. Is it the correct way to achieve this? Mark Cassidy You need to check the versioncount of the returned items. There are probably better ways to achieve this, but following your own code

Sitecore 7.5 MVC and HttpContext.Session.Timeout set to 1 min

夙愿已清 提交于 2019-11-30 15:49:01
问题 I have the session timeout set to 20min but when I try to access this value from action I'm getting 1min instead. Web.Config settings are: <sessionState mode="InProc" cookieless="false" timeout="20"> <authentication mode="None"> <forms name=".ASPXAUTH" cookieless="UseCookies" timeout="20" /> </authentication> In Global.asax.cs in Session_Start value of timeout is 20min : HttpContext.Current.Session.Timeout But in action in my controller is set to 1min : System.Web.HttpContext.Current.Session

Sitecore 7.5 MVC and HttpContext.Session.Timeout set to 1 min

梦想的初衷 提交于 2019-11-30 14:49:37
I have the session timeout set to 20min but when I try to access this value from action I'm getting 1min instead. Web.Config settings are: <sessionState mode="InProc" cookieless="false" timeout="20"> <authentication mode="None"> <forms name=".ASPXAUTH" cookieless="UseCookies" timeout="20" /> </authentication> In Global.asax.cs in Session_Start value of timeout is 20min : HttpContext.Current.Session.Timeout But in action in my controller is set to 1min : System.Web.HttpContext.Current.Session.Timeout HttpContext.Session.Timeout I've found that when I remove SitecoreHttpModule which is of type (