Interface IUmbracoComponentRenderer
Methods used to render umbraco components as HTML in templates
Namespace:System.Dynamic.ExpandoObject
Assembly:umbraco.dll
Syntax
public interface IUmbracoComponentRenderer
Methods
Field(IPublishedContent, String, String, String, String, String, Boolean, Boolean, Boolean, RenderFieldCaseType, RenderFieldEncodingType, Boolean, Boolean, String)
Declaration
IHtmlString Field(IPublishedContent currentPage, string fieldAlias, string altFieldAlias = "", string altText = "", string insertBefore = "", string insertAfter = "", bool recursive = false, bool convertLineBreaks = false, bool removeParagraphTags = false, RenderFieldCaseType casing = RenderFieldCaseType.Unchanged, RenderFieldEncodingType encoding = RenderFieldEncodingType.Unchanged, bool formatAsDate = false, bool formatAsDateWithTime = false, string formatAsDateWithTimeSeparator = "")
Parameters
Type | Name | Description |
---|---|---|
IPublishedContent | currentPage | |
System.String | fieldAlias | |
System.String | altFieldAlias | |
System.String | altText | |
System.String | insertBefore | |
System.String | insertAfter | |
System.Boolean | recursive | |
System.Boolean | convertLineBreaks | |
System.Boolean | removeParagraphTags | |
RenderFieldCaseType | casing | |
RenderFieldEncodingType | encoding | |
System.Boolean | formatAsDate | |
System.Boolean | formatAsDateWithTime | |
System.String | formatAsDateWithTimeSeparator |
Returns
Type | Description |
---|---|
System.Web.IHtmlString |
RenderMacro(String)
Renders the macro with the specified alias.
Declaration
IHtmlString RenderMacro(string alias)
Parameters
Type | Name | Description |
---|---|---|
System.String | alias | The alias. |
Returns
Type | Description |
---|---|
System.Web.IHtmlString |
RenderMacro(String, IDictionary<String, Object>)
Renders the macro with the specified alias, passing in the specified parameters.
Declaration
IHtmlString RenderMacro(string alias, IDictionary<string, object> parameters)
Parameters
Type | Name | Description |
---|---|---|
System.String | alias | The alias. |
System.Collections.Generic.IDictionary<System.String, System.Object> | parameters | The parameters. |
Returns
Type | Description |
---|---|
System.Web.IHtmlString |
RenderMacro(String, Object)
Renders the macro with the specified alias, passing in the specified parameters.
Declaration
IHtmlString RenderMacro(string alias, object parameters)
Parameters
Type | Name | Description |
---|---|---|
System.String | alias | The alias. |
System.Object | parameters | The parameters. |
Returns
Type | Description |
---|---|
System.Web.IHtmlString |
RenderTemplate(Int32, Nullable<Int32>)
Renders the template for the specified pageId and an optional altTemplateId
Declaration
IHtmlString RenderTemplate(int pageId, int ? altTemplateId = null)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | pageId | |
System.Nullable<System.Int32> | altTemplateId | If not specified, will use the template assigned to the node |
Returns
Type | Description |
---|---|
System.Web.IHtmlString |