- From: Simon Pieters <zcorpan@hotmail.com>
- Date: Sat, 09 Sep 2006 16:38:01 +0000
- To: annevk@opera.com, www-style@w3.org
Hi, From: "Anne van Kesteren" <annevk@opera.com> >It seems that the counters() construct doesn't really address the use case >of sections and headers. With a structure such as: > > <section> > <h>LEVEL 1</h> > <section> > <h>LEVEL 2</h> > </section> > <section> > <h>LEVEL 2</h> > </section> > </section> > >... I can't really find the a way to get an outline such as: > > 1. LEVEL 1 > 1.1 LEVEL 2 > 1.2 LEVEL 2 I believe this should work: :root, h + section { counter-reset:headers; } h::before { content:counters(headers, "."); counter-increment:headers; } Regards, Simon Pieters
Received on Saturday, 9 September 2006 16:38:22 UTC