sitecore

Sitecore Tree list datasource - VersionExist

a 夏天 提交于 2019-12-10 12:07:06
问题 in the Sitecore Treelist control, I want to get only the elements listed, which have a version on that language. I did a search and found out that there are parameters for including/excluding items/templates. But I cant give in a condition like Versions.Count > 0 Is there a way to do it by passing a parameter to the datasource field of the template? Or do I need to overwrite the treelist control? Thanx 回答1: This seems to work, but I didn't test it extensively... First create a class that

Custom Campaign URL in DMS 2.0

旧巷老猫 提交于 2019-12-10 11:34:47
问题 Edited The issue (#347688) has been fixed in Sitecore CMS 6.5.0 rev. 120427 (6.5.0 Update-4) and DMS 2.0.1 rev. 120427 We have been asked to explain where the editor can customize the campaign tracking url, they have seen the feature when participating in Sitecore Training sessions, but can't find the features in the our platform that is currently fully updated. It seems to me the feature has been removed otherwise it is hidden in {3AC13180-912F-4388-AF56-46A0F1172E70} that is missing in the

Sitecore Controller Rendering DataSource

社会主义新天地 提交于 2019-12-10 11:20:01
问题 I have a component in Sitecore that can be used in the middle section of the page. It shows a video and is setup as a controller rendering in Sitecore. I have been able to get this to work by setting the DataSource on the rendering on the page item. I have another component for the middle section of the page. This is a list of videos. Each video output has the exact same HTML as the rendering mentioned in the previous paragraph. I'm trying to call the controller rendering (mentioned above) in

How can I make sitecore showing an image (or other resources)

徘徊边缘 提交于 2019-12-10 10:54:52
问题 I installed clean Sitecore 6.6 and enabled MVC support using this guide. So my environment is Sitecore 6.6, ASP .NET MVC 3 and Razor, Microsoft SQL Server Express 2012, IIS 7.5 and I'm using Microsoft Visual Studio 2012 Express for Web. I have following code: @Model.PageItem.Fields["Title"];<br /> @Model.PageItem.Fields["Image"].GetValue(true, true);<br /> @Model.PageItem.Fields["Text"];<br /> Sitecore.Data.Items.MediaItem item = Model.PageItem.Fields["Image"].Item; @Sitecore.StringUtil

Missing Id field in Solr index

会有一股神秘感。 提交于 2019-12-10 10:09:34
问题 I just find out that my Solr index doesn't contain a _id field. and it is not possible to get item id. UniqueId is present but this is not really useful. public class MyClass { [IndexField(BuiltinFields.UniqueId)] public string UniqueId { get; set; } [IndexField(BuiltinFields.ID)] public int Id { get; set; } } How to add item id to Solr index ? What should I add to schema.xml ? Is next string would be enough ? <field name="_id" type="string" indexed="true" stored="true" required="true" /> If

Sitecore, custom MVC controllers and routes

此生再无相见时 提交于 2019-12-10 09:46:07
问题 I have a website defined in Sitecore's site definitions. The path to it is /localhost/mysite/home . And it works. I need to create a custom controller to submit forms with an API bypassing Sitecore. So I have FormsController (inheriting from MVC controller) with an action named "Test" taking no parameters. I defined the route in the initialize pipeline like this: public class Initialize { public void Process(PipelineArgs args) { MapRoutes(); GlassMapperSc.Start(); } private void MapRoutes() {

Sitecore create drop-down button in RTE populated from master database

假如想象 提交于 2019-12-10 05:40:07
问题 I'm trying to create a drop-down button for the rich text editor (RTE) in Sitecore but cannot figure out how to implement this. I would like something similar to the 'Insert Snippet' command shown below, but with the source of the dropdown driven by content from the master database instead of core items within the html editor profile. The closest approach I've found is this article which describes how to add a button which opens a dialog in the RTE. Another option could be to have a save

Get media url including server part

被刻印的时光 ゝ 提交于 2019-12-10 02:39:56
问题 Is it possible to get url with MediaManager.GetMediaUrl that always includes the server part? 回答1: Just to bump this up, in Sitecore 7 the AlwaysIncludeServerUrl option is also included in MediaUrlOptions (I don't know since which version of Sitecore) Like this: MediaUrlOptions muo = new MediaUrlOptions(); muo.AlwaysIncludeServerUrl = true; String url = MediaManager.GetMediaUrl((MediaItem)item, muo); 回答2: I've discovered that the following will work for producing fully qualified urls for

Web Forms for Marketers - Submit form data programmatically

落爺英雄遲暮 提交于 2019-12-09 23:41:37
问题 I'm currently scoping whether or not to include Web Forms for Marketers on a project I'm currently working on. The web site will be a responsive design with a rich UI and so I would like to have full control over the rendering of the form, e.g. labels, input fields etc and would rather not have to modify the WFFM SitecoreSimpleFormAscx.ascx file or the associated css file. Is there currently any way, using C# code, to submit some form data to a Web Forms for Marketers form that is already

Sitecore OMS - achieving a goal on a form submission

♀尐吖头ヾ 提交于 2019-12-09 19:34:54
问题 I inherited a Sitecore solution that has a sublayout that contains a complex ASP.NET ascx form which handles both payments and integration with 3rd party web services. This sublayout uses parameters templates to provide some level of control on the way the form looks like. The .ascx control contains multiple views: In the first view the user fills the form and click NEXT. In the second view the user can review the entered data before clicking the SUBMIT button. The third view is the thank you