3
I’m trying to get the following result:
Presentation
1.1. Content
1.2. Programming
1.2.1. JAVA
1.2.2. DOTNET
Completion
2.1. Acknowledgements
2.1.1 Family
2.1.2. Teachers
End
Through the following HTML
:
<ol>
<li>Apresentacao</li>
<ol>
<li> Conteudo </li>
<li> Programação </li>
<ol>
<li> JAVA </li>
<li> DOTNET </li>
</ol>
</ol>
<li>Conclusão</li>
<ol>
<li> Agradecimentos</li>
<ol>
<li> Família </li>
<li> Professores </li>
</ol>
</ol>
<li>Fim</li>
</ol>
I came closer through the following CSS
:
ol { counter-reset: item }
li { display: block }
li:before { content: counters(item, ".") " "; counter-increment: item }
But it still creates some problems.
Is there any feature of CSS
or HTML
to get my result?
What is still missing? The margins?
– Franchesco
@Earendul, he puts the wrong numbers.
– Diego Zanardo
Hmm, it is. I’ll see if I can...
– Franchesco