Lets say I have a list like this:
<ul style="list-style-type: upper-latin;">
<li>Lorem</li>
<li>Ipsum</li>
</ul>
(list-style-type
might be anything - upper-roman, katakana, lower-greek)
list-style-type: upper-latin;
will put a alphabet letter (starting from A) in front of every list item.
Is there a way to get this letter for any given list item? I can probably iterate over list using jQuery .index()
or similar.
Or, maybe there is way to extract markers from style?
The answer here works only for Latin alphabet lists.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…