[whatwg] image captions

Mihai Sucan mihai.sucan at gmail.com
Tue Jun 27 04:11:36 PDT 2006

Le Tue, 27 Jun 2006 13:00:21 +0300, dolphinling <lists at dolphinling.net> a  

> fantasai wrote:
>> I'm wondering what WA1 considers appropriate markup for
>> a figure with a caption.
>>  ~fantasai
> What's wrong with
> <div>
>    <img src="">
>    <p>This is the caption.</p>
> </div>
> ? That's how I think of it semantically, and I don't see it as being  
> common enough to warrant a separate element of its own.

There's nothing "wrong" with that. Yet, that's not exactly an image  
caption. There's no explicit association between the <img> and the  
following <p>.

Quick idea:

<img src="" caption="fig1">
<p id="fig1">This is the caption.</p>

How about this? It's backwards compatible. Maybe this has already been  
suggested (apologies if this is the case).

ROBO Design - We bring you the future

More information about the whatwg mailing list