Uploaded image for project: 'SonarHTML'
  1. SonarHTML
  2. SONARHTML-146

S???? - Ensure form tags have a method attribute

    XMLWordPrintable

    Details

    • Type: New Feature
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      Topic raised on the community:

      https://community.sonarsource.com/t/ensure-a-method-attribute-is-on-a-form-tag-in-html/53158

      By default, <form> tags in HTML will have the GET method if the method attribute is not specified. The rule should make sure that all <form> tags have a method attribute with a valid HTTP verb.

      Noncompliant:

      <form> 
      ...
      </form>
      

      Compliant:

      <form method="POST"> 
      ...
      </form>
      

      See also https://www.w3.org/TR/html401/interact/forms.html#h-17.3

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            gyula.sallai Gyula Sallai
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated: