Поделиться через


HtmlHelper.GetFormMethodString Method

Returns the HTTP method that handles form input (GET or POST) as a string.

Namespace:  System.Web.Mvc
Assembly:  System.Web.Mvc (in System.Web.Mvc.dll)

Syntax

'Declaration
Public Shared Function GetFormMethodString ( _
    method As FormMethod _
) As String
public static string GetFormMethodString(
    FormMethod method
)
public:
static String^ GetFormMethodString(
    FormMethod method
)

Parameters

Return Value

Type: System.String
The form method string, either "get" or "post".

Remarks

This method is used to render the form method as an XHTML attribute. Therefore, it returns a lowercase string.

See Also

Reference

HtmlHelper Class

System.Web.Mvc Namespace