u936293
u936293

Reputation: 16232

A <FORM> element disappears from the DOM

A fragment of my web output, when seen under Sources in Chrome Development Tools and Debugger in Edge is:

  </div>
  <form id="form" style="display:none;">
    <textarea class="form-control" id="editor" name="editor"></textarea>
    <input class="btn btn-primary" type="submit" value="Submit">
    <button class="btn btn-default" onclick="discard();" type="button">Cancel</button>
  </form>
  <!--**END**-->

However, under Elements in Chrome and DOM Explorer in Edge, the <form> element is missing, as follows:

enter image description here

Though I have some scripts, none of them did anything to the <form> element. What could be causing the anomaly?

Upvotes: 5

Views: 1734

Answers (1)

Super User
Super User

Reputation: 9642

You can check your DOM. Form element can not generate as a nested. may be there is another form element exist in parent tag.

Upvotes: 12

Related Questions