This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Web.Mvc; | |
namespace System.Web.UI | |
{ | |
public static class PageCommon | |
{ | |
public static UrlHelper GetUrlHelper(this Control c) | |
{ | |
return new UrlHelper(c.Page.Request.RequestContext); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var XSLT = @" | |
<stylesheet version=""1.0"" | |
xmlns=""http://www.w3.org/1999/XSL/Transform""> | |
<output omit-xml-declaration=""yes"" | |
method=""xml"" | |
cdata-section-elements=""script"" /> | |
<template match=""/""> | |
<apply-templates select=""*"" /> | |
</template> | |
<template match=""body|p|br|ol|ul|li|sup|sub|a|table|tr|td|th|hr|h2|h3|h4|h5|h6""> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Linq; | |
using Tridion.ContentManager.ContentManagement.Fields; | |
using Tridion.ContentManager.Templating; | |
using Tridion.ContentManager.Templating.Assembly; | |
using comm = Tridion.ContentManager.CommunicationManagement; | |
namespace Tridion.Training.Assemblies | |
{ | |
[TcmTemplateTitle("Component Array")] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections.Generic; | |
namespace System.Linq | |
{ | |
public static class EnumerableExtension | |
{ | |
public static IEnumerable<T> Generate<T>(this T seed) | |
{ | |
return new T[] { seed }; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using Microsoft.Practices.ServiceLocation; | |
using Microsoft.Practices.Unity; | |
namespace Alitalia.ConsumerWeb.Mapping.Tridion | |
{ | |
public class BuilderFactory | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
namespace DD4T.ContentModel | |
{ | |
/// <summary> | |
/// Shortcuts for accessing component fields. | |
/// </summary> | |
public static partial class FieldsExtensions |