Quick answer : append the form to the body.
document.body.appendChild(form);
Or, if you’re using jQuery as above: $(document.body).append(form);
Details : According to the HTML standards, if the form is not associated to the browsing context(document), the form submission will be aborted.
HTML SPEC see 4.10.21.3.2
In Chrome 56, this spec was applied.
Chrome code diff see @@ -347,9 +347,16 @@
P.S about your question #1. In my opinion, unlike ajax, form submission causes instant page move.
So, showing ‘deprecated warning message’ is almost impossible.
I also think it’s unacceptable that this serious change is not included in the feature change list. Chrome 56 features – www.chromestatus.com/features#milestone%3D56
Related Posts:
- Getting Error “Form submission canceled because the form is not connected”
- Error OPTIONS net::ERR_CONNECTION_REFUSED
- Export html table data to Excel using JavaScript / JQuery is not working properly in chrome browser
- Failed to load resource: net::ERR_CONTENT_LENGTH_MISMATCH
- How to use jQuery in chrome extension?
- Disable Chrome strict MIME type checking
- Chrome/jQuery Uncaught RangeError: Maximum call stack size exceeded
- “Uncaught TypeError: a.indexOf is not a function” error when opening new foundation project
- How do I redirect to another webpage?
- Uncaught ReferenceError: jQuery is not defined [duplicate]
- How do I check whether a checkbox is checked in jQuery?
- syntax error: unexpected token <
- Uncaught ReferenceError: jQuery is not defined [duplicate]
- JQuery – $ is not defined
- Cannot read property ‘push’ of undefined when combining arrays
- Download File Using JavaScript/jQuery
- Disabling and enabling a html input button
- Check if checkbox is checked with jQuery
- How can I get the data-id attribute?
- document.getElementById vs jQuery $()
- Check if checkbox is checked with jQuery
- How to import jquery using ES6 syntax?
- How to filter an array/object by checking multiple values
- Infinite Scrolling in Asp.Net MVC with jQuery / AJAX Issues
- What are the difference between $(document).bind(‘ready’, function) and $(document).ready(function() {})
- How can jQuery deferred be used?
- Uncaught TypeError : cannot read property ‘replace’ of undefined In Grid
- Disable/enable an input with jQuery?
- What does on() in JavaScript do?
- How to use php code in javascript
- What’s the difference between console.dir and console.log?
- Use images like checkboxes
- How to read xml file contents in jQuery and display in html elements?
- JavaScript error (Uncaught SyntaxError: Unexpected end of input)
- How can I print using JQuery
- Loading local JSON file
- How to check all checkboxes using jQuery?
- ChangeDate – Date Picker Bootstrap
- Uncaught TypeError: Cannot read property ‘msie’ of undefined
- How to hide a div with jQuery?v
- How do I set/unset a cookie with jQuery?
- keycode 13 is for which key
- How to update array value javascript?
- Equivalent of jQuery .hide() to set visibility: hidden
- How can I get the last character in a string?
- Uncaught TypeError: Cannot read property ‘name’ of undefined
- TypeError: $(…).DataTable is not a function
- jQuery explode string like PHP
- Validate date in dd/mm/yyyy format using JQuery Validate
- Dynamically load JS inside JS
- Simulate Keypress With jQuery
- Adding options to a
- How to add an object to an array
- jQuery Ajax POST example with PHP
- Setting and getting localStorage with jQuery
- this vs $(this)
- Javascript isnull
- Set value to currency in
- How to open a URL in a new Tab using JavaScript or jQuery?
- Extract hostname name from string
- jquery beforeunload when closing (not leaving) the page?
- how to get the value of a textarea in jquery?
- How do I pass the this context to a function?
- Escaping HTML strings with jQuery
- How to use z-index in svg elements?
- Why define an anonymous function and pass it jQuery as the argument?
- How to scroll an HTML page to a given anchor
- What is the best way to detect a mobile device?
- How to filter JSON Data in JavaScript or jQuery?
- Get querystring from URL using jQuery [duplicate]
- jQuery checkbox change and click event
- jQuery selectors on custom data attributes using HTML5
- How do I refresh a DIV content?
- TypeError: abc.getAttribute is not a function
- jQuery sort elements using data id
- Uncaught SyntaxError: Unexpected token with JSON.parse
- TypeError getElementsByTagName is not a function issue
- How to open a Bootstrap modal window using jQuery?
- window.location.replace() not working to redirect browser
- How to check if the URL contains a given string?
- Check if url contains string with JQuery
- jquery to validate phone number
- Closing Bootstrap modal onclick
- stopPropagation vs. stopImmediatePropagation
- What’s a Good Javascript Time Picker?
- Ajax success function
- How can I exit from a javascript function? [duplicate]
- Cannot read property ‘preventDefault’ of undefined in javascript error
- Object doesn’t support property or method ‘addEventListener’
- How to fix javascript .toFixed is not a Function error
- jQuery checkbox checked state changed event
- etect the Enter key in a text input field
- WordPress 5.5 – ReferenceError: commonL10n is not defined error
- Jquery function working in Chrome Console but not in the code [closed]
- How to set callback to execute after all the tinyMCE editors have been initialized?
- How do I make my wordpress post appear in a mouse hover preview?
- Change each text after 4 second and each image after 2 second
- wp post_tag change minlength
- How to locate the js code and php code for certain function?
- Use one javascript variable into another javascript file