[whatwg] <code> attributes

On Tue, 28 Apr 2009 15:16:59 -0400, Jacob Rask <jacob at jacobrask.net> wrote:

> Hi,
> has there ever been any discussion on including an attribute to the
> code element, specify the programming language in the markup? If so,
> what was the conclusion? I didn't find anything in the list archives.
>
> If not, I believe it would be a very good idea. Browsers could for
> instance have default color codings for different languages, open
> selected code/text in an editor associated with that language, etc...
>
> -- Jacob Rask

<http://www.whatwg.org/specs/web-apps/current-work/multipage/text-level-semantics.html#the-code-element>

For example:
<code class="language-python"></code>

-- 
Michael

Received on Tuesday, 28 April 2009 19:21:14 UTC