Widget code produces XHTML 1.0 Transitional validation warning


#1
     Here is the code. It does work but keeps giving warnings.

Tweets by @BLS_gov

      </a>

Warning 1 Validation (XHTML 1.0 Transitional): Attribute ‘data-widget-id’ is not a valid attribute of element ‘a’. C:\Documents and Settings\Homeuser\my documents\visual studio 2010\Projects\Basic\Basic\Site.Master 47 67 Basic
Warning 2 Validation (XHTML 1.0 Transitional): Element ‘script’ is missing required attribute ‘type’. C:\Documents and Settings\Homeuser\my documents\visual studio 2010\Projects\Basic\Basic\Site.Master 48 14 Basic


#2

A data-* element is a way of embedding custom, non-visible data in HTML read by the Twitter widgets JavaScript.
https://html.spec.whatwg.org/multipage/dom.html#embedding-custom-non-visible-data-with-the-data-*-attributes

Modern browsers treat the contents of a script element as text/javascript if the type attribute is omitted.
https://html.spec.whatwg.org/multipage/scripting.html#the-script-element


#3

So are you saying I should modify the auto generated code?


#4

The results of the validation tests against the XHTML 1.0 Transitional DTD are correct yet do not affect the execution of the Embedded Timeline widget in a browser.

If conforming to a doctype is important to you or your site you might consider a DTD-less DOCTYPE declaration.
http://msdn.microsoft.com/en-us/library/ie/gg699338.aspx


#5