Share via


FormActionTagHelper Class

Definition

ITagHelper implementation targeting <button> elements and <input> elements with their type attribute set to image or submit.

public ref class FormActionTagHelper : Microsoft::AspNetCore::Razor::TagHelpers::TagHelper
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-action")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-controller")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-area")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-fragment")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-route")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-all-route-data")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-route-*")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-action", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-controller", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-area", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-fragment", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-route", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-all-route-data", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-route-*", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-action", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-controller", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-area", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-fragment", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-route", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-all-route-data", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-route-*", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
public class FormActionTagHelper : Microsoft.AspNetCore.Razor.TagHelpers.TagHelper
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-action")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-controller")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-area")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-fragment")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-route")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-all-route-data")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-route-*")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-action", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-controller", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-area", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-fragment", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-route", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-all-route-data", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-route-*", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-action", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-controller", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-area", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-fragment", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-route", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-all-route-data", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-route-*", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-page")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-page-handler")]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-page", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-page-handler", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-page", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
[Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-page-handler", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)]
public class FormActionTagHelper : Microsoft.AspNetCore.Razor.TagHelpers.TagHelper
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-action")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-controller")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-area")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-fragment")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-route")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-all-route-data")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-route-*")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-action", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-controller", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-area", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-fragment", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-route", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-all-route-data", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-route-*", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-action", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-controller", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-area", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-fragment", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-route", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-all-route-data", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-route-*", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
type FormActionTagHelper = class
    inherit TagHelper
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-action")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-controller")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-area")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-fragment")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-route")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-all-route-data")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-route-*")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-action", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-controller", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-area", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-fragment", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-route", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-all-route-data", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-route-*", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-action", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-controller", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-area", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-fragment", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-route", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-all-route-data", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-route-*", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-page")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("button", Attributes="asp-page-handler")>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-page", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=image], asp-page-handler", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-page", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
[<Microsoft.AspNetCore.Razor.TagHelpers.HtmlTargetElement("input", Attributes="[type=submit], asp-page-handler", TagStructure=Microsoft.AspNetCore.Razor.TagHelpers.TagStructure.WithoutEndTag)>]
type FormActionTagHelper = class
    inherit TagHelper
Public Class FormActionTagHelper
Inherits TagHelper
Inheritance
FormActionTagHelper
Attributes

Constructors

FormActionTagHelper(IUrlHelperFactory)

Creates a new FormActionTagHelper.

Properties

Action

The name of the action method.

Area

The name of the area.

Controller

The name of the controller.

Fragment

Gets or sets the URL fragment.

Order

When a set of ITagHelpers are executed, their Init(TagHelperContext)'s are first invoked in the specified Order; then their ProcessAsync(TagHelperContext, TagHelperOutput)'s are invoked in the specified Order. Lower values are executed first.

Page

The name of the page.

PageHandler

The name of the page handler.

Route

Name of the route.

RouteValues

Additional parameters for the route.

UrlHelperFactory

Gets the IUrlHelperFactory used to create an IUrlHelper to generate links.

ViewContext

Gets or sets the ViewContext for the current request.

Methods

Init(TagHelperContext)

Initializes the ITagHelper with the given context. Additions to Items should be done within this method to ensure they're added prior to executing the children.

(Inherited from TagHelper)
Process(TagHelperContext, TagHelperOutput)

Synchronously executes the TagHelper with the given context and output.

ProcessAsync(TagHelperContext, TagHelperOutput)

Asynchronously executes the TagHelper with the given context and output.

(Inherited from TagHelper)

Applies to