[whatwg] Use of article to identify the main content of a web page

Ian Hickson ian at hixie.ch
Mon Nov 19 10:08:05 PST 2012


On Mon, 19 Nov 2012, Ian Yang wrote:
> On Sat, Nov 17, 2012 at 8:01 AM, Ian Hickson <ian at hixie.ch> wrote:
> > On Thu, 15 Nov 2012, Ian Yang wrote:
> > >
> > > That's a good idea. We really need an element to wrap all the <p>s, 
> > > <ul>s, <ol>s, <figure>s, <table>s ... etc of a blog post.
> >
> > That's called <article>.
> 
> Thanks Hickson. Actually I had turned down my own opinion ( 
> http://lists.w3.org/Archives/Public/public-whatwg-archive/2012Nov/0182.html 
> ).
> 
> And isn't <article> used to wrap an entire blog post? Like this:
> 
> <article>
>     <header />
>     <div />
>     <footer />
> </article>

Right. It wraps all the elements of a blog post. All the <p>s, <ul>s, 
<ol>s, <figure>s, <table>s, <h1>s, <footer>s, etc.

If you just want to wrap a subpart of that for rendering purposes, <div> 
is the element you want. Basically <div> is always the answer if the 
question is "how do I provide myself a hook for CSS styling".

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'



More information about the whatwg mailing list