W3C validator bookmarklet
The bookmarklet below can be used to validate the current HTML page
using the W3C engine:
(just drag the above link to your bookmakrs toolbar)
Advantages over other similar bookmarklets:
However, limitations remain:
- Works for localhost files (submits page contents to W3C validator rather than just its URL)
- Works for pages that are the result of a POST (doesn't refetch page)
- Preserves lines (using textarea to submit contents instead of hidden input)
- The <!DOCTYPE > line is re-generated rather than taken from source
- Same remark for the enclosing <html> tags.
- Doesn't work for XHTML
- Doesn't flag errors related to unescaped ampersands (&) because the innerHTML "helpfully" escapes them...
Last modified: Tue Mar 13 21:27:57 CET 2012