W3C home > Mailing lists > Public > public-html@w3.org > June 2007

Re: <code type="...">

From: Thomas Pike <thomasp@opera.com>
Date: Fri, 22 Jun 2007 11:19:13 +0200
Message-ID: <467B9411.2030600@opera.com>
To: Maurice Carey <maurice@thymeonline.com>
CC: HTML Working Group <public-html@w3.org>

Maurice Carey wrote:
> On 6/21/07 11:20 AM, "Josh Sled" <jsled@asynchronous.org> wrote:
>>> JS> Also, I note the analog with <object type=...>.
>>> There is no analogy,
>>> because |type| of OBJECT specify technical characteristic,
>>> but |type| of _all_ tags at all specify semantic characteristic.
>> In the same way that <object type> specifies a technical characteristic (the
>> media type) of the referenced object, <code type> would specify a technical
>> characteristic (the media type) of the in-lined code.
> And then it would be easier for extension developers to write things the
> color code code blocks for people like me who spend a lot of time reading
> code on peoples web pages that's often not color coded.
> ....
> I'm not suggesting html have anything to do with defining color coding rules
> or anything of the sort. But I do agree that extra bit of important
> information would be Very useful to many people.

While the information may indeed be useful for such things, would it not
better belong in the lang="" attribute?

As far as I'm aware this is valid even now:

<code lang="x-php">
&lt;?php echo "Hello world!" ?&gt;
</code>

-- 
Thomas Pike
QA Engineer, Opera Software
Received on Friday, 22 June 2007 09:19:29 UTC

This archive was generated by hypermail 2.3.1 : Monday, 29 September 2014 09:38:45 UTC