Class HtmlDisplayNameExtensions
Provides a mechanism to get display names.
Inheritance
Namespace: DotNetNuke.Web.Mvc.Helpers
Assembly: DotNetNuke.Web.Mvc.dll
Syntax
public static class HtmlDisplayNameExtensions : object
Methods
| Improve this Doc View SourceDisplayName(DnnHtmlHelper, String)
Gets the display name.
Declaration
public static MvcHtmlString DisplayName(this DnnHtmlHelper html, string expression)
Parameters
| Type | Name | Description |
|---|---|---|
| DnnHtmlHelper | html | The HTML helper instance that this method extends. |
| System.String | expression | An expression that identifies the object that contains the display name. |
Returns
| Type | Description |
|---|---|
| MvcHtmlString | The display name. |
DisplayNameFor<TModel, TValue>(DnnHtmlHelper<TModel>, Expression<Func<TModel, TValue>>)
Gets the display name for the model.
Declaration
public static MvcHtmlString DisplayNameFor<TModel, TValue>(this DnnHtmlHelper<TModel> html, Expression<Func<TModel, TValue>> expression)
Parameters
| Type | Name | Description |
|---|---|---|
| DnnHtmlHelper<TModel> | html | The HTML helper instance that this method extends. |
| Expression<Func<TModel, TValue>> | expression | An expression that identifies the object that contains the display name. |
Returns
| Type | Description |
|---|---|
| MvcHtmlString | The display name for the model. |
Type Parameters
| Name | Description |
|---|---|
| TModel | The type of the model. |
| TValue | The type of the value. |
DisplayNameFor<TModel, TValue>(DnnHtmlHelper<IEnumerable<TModel>>, Expression<Func<TModel, TValue>>)
Gets the display name for the model.
Declaration
public static MvcHtmlString DisplayNameFor<TModel, TValue>(this DnnHtmlHelper<IEnumerable<TModel>> html, Expression<Func<TModel, TValue>> expression)
Parameters
| Type | Name | Description |
|---|---|---|
| DnnHtmlHelper<IEnumerable<TModel>> | html | The HTML helper instance that this method extends. |
| Expression<Func<TModel, TValue>> | expression | An expression that identifies the object that contains the display name. |
Returns
| Type | Description |
|---|---|
| MvcHtmlString | The display name for the model. |
Type Parameters
| Name | Description |
|---|---|
| TModel | The type of the model. |
| TValue | The type of the value. |
DisplayNameForModel(DnnHtmlHelper)
Gets the display name for the model.
Declaration
public static MvcHtmlString DisplayNameForModel(this DnnHtmlHelper html)
Parameters
| Type | Name | Description |
|---|---|---|
| DnnHtmlHelper | html | The HTML helper instance that this method extends. |
Returns
| Type | Description |
|---|---|
| MvcHtmlString | The display name for the model. |