-
Notifications
You must be signed in to change notification settings - Fork 739
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
generated markup invalid for xhtml #450
Comments
I patched jquery.contextMenu.js to use https://andreasplesch.github.io/cobweb_dom/jQuery-ContextMenu/input_fixed.xhtml In the process, it turned out that the The patched js works with the html encoding as well. I tested on Chrome 52.02, FF 47 and IE11 on Windows 7. Also on Android Chrome 52.02 and FF 48. I could prepare a PR; the changes are rather trivial. |
Thanks for putting in the effort to create a patch. I'm on vacation right now, but will have a look at your pr when it arrived. |
PR #451 submitted. |
Thanks, from what i read it is valid in HTML5 also, but not in HTML4. But will have a look soon. |
My understanding is that still recognizes it as strictly valid. There are not many jquery based web pages which use HTML4 left but there may be only a few more which use XHTML. The only browsers which may complain are perhaps IE6 or IE7 ? |
I created a simplistic html4 page to test: or better https://andreasplesch.github.io/cobweb_dom/jQuery-ContextMenu/Inputv4.html IE6 on Netrenderer.com is happy with it. https://developer.microsoft.com/en-us/microsoft-edge/tools/screenshots/ is another option. It works with the gh page and all tested browser (IE8 to edge, latest FF and Chrome, Safari, Android) are rendering correctly, eg. do not complain about Screenshots for all tested browsers are successfully generated. |
Any plans or questions about this PR ? If it is lower priority as a new feature, we would start to maintain and use a fork downstream. |
I will look at it soon, and talk with some colleagues if they think this might be problematic, if not, it'll be merged :) |
ok, thanks. I can understand that this is perhaps seen as risky given that xhtml is not used much. But I could not find a scenario where |
PR merged |
The radio type (and perhaps others) generate invalid markup for a xhtml document. This results in a fatal exception.
"<input />"
would be compatible with both html and xhtml encoding.Here is input menu demo as html:
https://andreasplesch.github.io/cobweb_dom/jQuery-ContextMenu/input.html
and as xhtml:
https://andreasplesch.github.io/cobweb_dom/jQuery-ContextMenu/input.xhtml
There is this console message:
Uncaught SyntaxError: Failed to set the 'innerHTML' property on 'Element': The provided markup is invalid XML, and therefore cannot be inserted into an XML document.
The text was updated successfully, but these errors were encountered: