Class TextFieldTagHelper

Version: 21.x

Tag helper that renders text for a Sitecore TextField.

Inheritance
System.Object
TextFieldTagHelper
Namespace: Sitecore.AspNet.RenderingEngine.TagHelpers.Fields
Assembly: Sitecore.AspNet.RenderingEngine.dll
Syntax
RequestResponse
public class TextFieldTagHelper : TagHelper

Constructors

TextFieldTagHelper()

Declaration
RequestResponse
public TextFieldTagHelper()

Properties

ConvertNewLines

Gets or sets a value indicating whether to convert line endings to
tags.

Declaration
RequestResponse
public bool ConvertNewLines { get; set; }
Property Value
TypeDescription
System.Boolean

Editable

Gets or sets a value indicating whether the field can be edited.

Declaration
RequestResponse
public bool Editable { get; set; }
Property Value
TypeDescription
System.Boolean

For

Gets or sets the model value.

Declaration
RequestResponse
public ModelExpression For { get; set; }
Property Value
TypeDescription
Microsoft.AspNetCore.Mvc.ViewFeatures.ModelExpression

Methods

Process(TagHelperContext, TagHelperOutput)

Declaration
RequestResponse
public override void Process(TagHelperContext context, TagHelperOutput output)
Parameters
TypeNameDescription
Microsoft.AspNetCore.Razor.TagHelpers.TagHelperContextcontext
Microsoft.AspNetCore.Razor.TagHelpers.TagHelperOutputoutput

Do you have some feedback for us?

If you have suggestions for improving this article,