Pesquisar no site de suporte

Evite golpes de suporte. Nunca pedimos que você ligue ou envie uma mensagem de texto para um número de telefone, ou compartilhe informações pessoais. Denuncie atividades suspeitas usando a opção “Denunciar abuso”.

Saiba mais

Esta discussão foi arquivada. Faça uma nova pergunta se precisa de ajuda.

wrong numbering of elements styled with "display: list-item; list-style-type: decimal;"

  • 1 resposta
  • 5 têm este problema
  • 2 visualizações
  • Última resposta de dmuller

more options

Following code :

<style type="text/css">

div {
 display: block;
 margin-left: 2em;
}
span {
 display: list-item;
 list-style-type: decimal;
}

</style>

<div>

 <span>first</span>
 <span>second</span>
 <span>third</span>

</div>

Displays as :

0. first
0. second
0. third 

while looking fine in other browsers (checked IE7, chrome, opera, safari...)

Following code : <!DOCTYPE html> <style type="text/css"> div { display: block; margin-left: 2em; } span { display: list-item; list-style-type: decimal; } </style> &lt;div> &lt;span>first&lt;/span> &lt;span>second&lt;/span> &lt;span>third&lt;/span> &lt;/div> Displays as : 0. first 0. second 0. third while looking fine in other browsers (checked IE7, chrome, opera, safari...)

Alterado por dmuller em

Todas as respostas (1)

more options

updated code snap...

Alterado por dmuller em