dropshado.ws

Front-end development minutiæ

by David DeSandro

Archive
RSS feed
Twitter
GitHub Pages mirror

output element

The output element represents the result of a calculation.

Ideal to be used with range inputs, as Mike Taylor demonstrates.

2 Sep 2011
  • HTML
  • HTML5
  • markup

Type attribute in script element

The type attribute gives the language of the script or format of the data. If the attribute is present, its value must be a valid MIME type. The charset parameter must not be specified. The default, which is used if the attribute is absent, is "text/javascript"

To resolve a question in the HTML5 Boilerplate repo. Important to note is that the details provided on w3schools misleads that the type attribute is required.

27 Oct 2010
  • html
  • html5
  • markup

HTML 5 Reference : 3.2.3 Attributes

There are four slightly different syntaxes that may be used for attributes in HTML: empty, unquoted, single-quoted and double-quoted.

This can be useful for escaping quotes in attributes, as seen in this example from the recent jQuery 1.4.3 release notes:

<div data-options='{"name":"John"}'></div>
25 Oct 2010
  • HTML
  • syntax
  • markup
  • desandro.com
  • @desandro
  • github.com/desandro
  • desandro’s JS Fiddles