- 1 Extra indentation of lists
- 2 Paragraphs in lists
- 3 </p> Tags
- 4 Alphabetic bullet point lists
- 5 Flaw in the syntax
- 6 Out of order lists
- 7 Can we put a table in a numbered list?
- 8 Help:List#Numbered list across sections
- 9 Unordered Multi Column Lists
- 10 Numbering table rows
- 11 1.1, 1.2, 1.2.1 numbering
- 12 Mass deletion of obsolete lists on Wikipedia
- 13 Automated multi-column lists
- 14 Outline Numbered List
- 15 Multi-column lists don't work in IE
- 16 help!!! i cant create a deeper level list!!!
- 17 The HTML <li value="..."> syntax may be combined with the wikicode # markup
- 18 I want to continue at the correct indent after having inserted a list
- 19 Badly needed overhaul
- 20 changing glyph used for unordered lists
- 21 Changed indent
- 22 continuing list after a preformatted text
- 23 Simple templates for multi-column lists
- 24 Colon in text creates new item
- 25 List-agnostic markup insertions
Extra indentation of lists
<ul> for "extra indentation" seems strange. Couldn't we recommend
<ol style="margin-left: 3em;">?
- Not only strange, it is plain wrong.
Agreed. Even using : to indent replies on talk pages (like I am doing right now), is wrong, since : is actually a definition list. — Omegatron 22:38, 18 March 2006 (UTC)
- colon is not a definition list.
It is true that the combination of semicolon (;) and colon (:) forms a definition list.
- Just at it is true that the two atoms of hydrogen and one of oxygen forms a water molecule.
whoops! I made faux pas. I used an asterisk to emphasis a point with a bullet but I didn't make a bulleted list so I must be violating someone's idea of what is syntacticly correct convention. (sic)
- If I just wanted a bold text paragraph I could precede it with a semicolon instead of wrapping it in three single quotes. It does not make this paragraph a definition but it does leverage a piece of markup used in a definition list.
Are we smiling yet ? ;-)
- Said differently
- I prefer to think of (;) and (:) as atoms and a "Definition List" as a molecule !
(Najevi 13:01, 11 May 2008 (UTC))
Paragraphs in lists
Rather than the double <br> technique, I find <p> tags work provided the second and subsequent paragraphs have <p> and </p> around them.
#Abc dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text.<p>Def dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text.</p> #Ghi dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text.<p>Jkl dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text.</p>
- Abc dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text.
Def dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text.
- Ghi dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text.
Jkl dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text.
Examination of the HTML produced by Wiki shows that the tags are just copied into the output so you do end up with a genuine paragraph in a list item. This means that it should render correctly on all browsers.
Omitting the closing </p> tag causes paragraph rendering to go wrong later in the page (the next time you try and use this trick).
I don't know if this works by accident or by design. If it's deliberate then the Help:List should be updated to recommend this technique in preference to <br><br>.
</p> This is an HTML and as you say ommiting it causes problems. However this is the fault of HTML and not Wikipedia. - anon.
Alphabetic bullet point lists
Is there a MediaWiki way to make a "lettered" list? For example:
a. <item> b. <item> c. <item>
Aside of course from just lettering each item manually? In OpenWiki, for example, putting "a." at the beginning of each element will do this, but MediaWiki doesn't seem to have the same functionality. Elonka 23:09, 6 January 2006 (UTC)
You can use real HTML, but that seems to be it
- Item one
- Item two
- Item three
— Omegatron 22:54, 18 March 2006 (UTC)
Providing raw code for reference:
<ol style="list-style-type:lower-alpha;"> <li> Item one </li> <li> Item two </li> <li> Item three </li> </ol>
--Elonka 23:23, 11 April 2007 (UTC)
- Which is a roundabout way of saying: no. --184.108.40.206 00:51, 31 January 2013 (UTC)
Flaw in the syntax
There is something complete wrong in either the wiki syntax or its usage:
Everyone uses colons to indent text, especially on talk pages.
: this line is indented
So far, so good, but when you look at the generated HTML code, it looks like this:
<dl> <dd>this line is indented</dd> </dl>
This means that definition lists are abused for styling purposes. This is fundamentely wrong.
excerpt from the HTML 4.01 recommendation:
We discourage authors from using lists purely as a means of indenting text. This is a stylistic issue and is properly handled by style sheets.
--220.127.116.11 17:48, 7 January 2006 (UTC)
- Agreed that using lists to indent is wrong. Then again, talk pages with replies could be considered a type of list. That page also says
I also remember reading somewhere on the w3c site that they consider the semantic meaning of definition lists to be pretty loosely defined; you can use it for lots of things besides strict definitions. — Omegatron 22:49, 18 March 2006 (UTC)
Another application of DL, for example, is for marking up dialogues, with each DT naming a speaker, and each DD containing his or her words.
- Using style sheets instead of a simple
:(colon) for indenting is ridiculous overkill. If MediaWiki just had some clever markup for proper indenting, people would use it, but MediaWiki gave us an easy to use, flawed tool, but we don't see the flaws... just the easy to use. If the MediaWiki folks wanted us to use something else, they should have provided it. Sadly, they didn't. --18.104.22.168 00:54, 31 January 2013 (UTC)
- Using style sheets instead of a simple
Out of order lists
Is it worth pointing out that you can do out-of-order lists with HTML?
It's kind of kludgy, and should probably be rarely used, but the rendered output is perfectly valid HTML. — Omegatron 23:02, 18 March 2006 (UTC)
Can we put a table in a numbered list?
Help! I'd like to make a numbered list which includes same tables within each of the list items. How to do that without restarting the list number to 1? Putting "#:" on each line of the table just destroys the table. Sentausa 09:40, 6 July 2006 (UTC)
Should this be here? It has very little use, has distinct drawbacks and can by achieved by other methods (which have drawbacks of their own... ). I'd say that the section should go for the sake of simplicity. --Swift 20:50, 31 July 2006 (UTC)
- The complication seems to have been fixed. Splitting up a long numbered list can be useful for easy editing.--Patrick 23:26, 31 July 2006 (UTC)
- This complication wasn't my only concern. I'll agree that this may be the best way to do it in wikitext but have two objections, though:
- This method puts the first h3 element in a definition list (which will indent it compared to other level 3 headings on the page) and the following ones in an (un)ordered list. These won't neccessarily indent equally (they don't on my broser) so not even consistancy between these headings is guaranteed. As it makes assumptions about the styling, it does not belong in the markup.
- Splitting a continuous list across multiple sections doesn't make a lot of sense, semantically. I can see that it might be useful for counting the total number of items in all lists. I'd like to see an actual example where this is useful.
- This is an akward hack for a something that I don't think is all that useful. I would recommend using HTML to solve this more elegantly by setting the counter in each section. With CSS this can probably be solved properly. --Swift 00:46, 1 August 2006 (UTC)
- This complication wasn't my only concern. I'll agree that this may be the best way to do it in wikitext but have two objections, though:
- Okay, I removed it. In IE the indentations are the same, but I agree that in Opera it is ugly.--Patrick 08:40, 1 August 2006 (UTC)
- I recently updated to Mediawiki 1.24 and found that the sections no longer break up the numbering and the indentations are awful looking. How do I fix that? --22.214.171.124 06:21, 15 January 2015 (UTC)
Unordered Multi Column Lists
Is it possible, such that it would look like:
- Item 1 * Item 2 * Item 3
- Item 1 * Item 4
- item 2 * Item 5
- Item 3 * Item 6
- Yes, I added Help:List#Multi-column_bulleted_list.--Patrick 22:37, 7 October 2006 (UTC)
- It doesn't work for IE7.0. Any ideas? Is there alternative way? --Dnikitin 22:23, 29 December 2008 (UTC)
Numbering table rows
Can anyone tell me please - how can i make an automatic numbering of table rows. # and * does not work. li as well (wiki puts ul before it automatically). ol before talbe does not help as well... Elk Salmon 11:40, 7 November 2006 (UTC)
1.1, 1.2, 1.2.1 numbering
Often other types of numbering is needed, like
1. Main item 1.1 First sub item 1.2 Next sub item 1.2.1 Sub sub item 1.2.2 Sub sub item 1.3 One more 2. Next main item 3. One more main item 3.1 etc 3.2 etc
Is this not possible? --126.96.36.199 14:05, 21 November 2006 (UTC)
I'm looking for something like this as well. Don't see anything here, but I will keep looking. 188.8.131.52 02:22, 6 January 2007 (UTC)
Mass deletion of obsolete lists on Wikipedia
Please see w:Wikipedia:Village_pump_(proposals)#Mass_deletion_of_obsolete_lists.--Piotrus 19:59, 21 April 2007 (UTC)
Automated multi-column lists
See Template talk:Multi-column numbered list#Automated multi-column list. -Eep² 22:48, 5 August 2007 (UTC)
Should the CSS3 style modifiers be last in the list?
I looked at the link and nearly had a heart-attack at the complexity. I read at this link a much simpler method to future proof your mark up.
<!-- Multi-column format --> <div style="-moz-column-count:2; -moz-column-width:20em; -moz-column-gap:1em; <!-- gecko/mozilla --> -webkit-column-count:2;-webkit-column-width:20em;-webkit-column-gap:1em; <!-- webkit/safari --> column-count:2; column-width:20em; column-gap:1em;"> <!-- CSS3 future proof -->
According to the article it is significant that the CSS3 style parameters be last in the list so as to override the preceding parameters whenever CSS3 is supported by a browser.
So if you really felt it necessary to use a template then it need only accept (count, width, gap) and then have it generate a block of mark up like the above.
- Which brings me to my reason for contributing to the discussion.
- If placing the CSS3 style modifier last is indeed significant then perhaps the list demos that illustrate CSS3 styles should establish that good example.
I am not experienced enough to know but am wary enough to ask! (Najevi 12:27, 11 May 2008 (UTC))
Outline Numbered List
Is there a way to create a list that is numbered as an outline? The list below is formatted how I'd like it (but not automatically numbered):
- 1. element 1 level 1
- 1.1. subelement 1 level 2
- 1.2. subelement 2 level 2
- 1.2.1. subsubelement 1 level 3
- 1.3. subelement 3 level 2
- 2. element 2 level 1
I know how to do a general list, but that only gives me:
- element 1 level 1
- subelement 1 level 2
- subelement 2 level 2
- subsubelement 1 level 3
- subelement 3 level 2
- element 2 level 1
I know that the table of contents does this automatically, and if the user has the automatic numbering preference enabled, the numbers will appear if each entry is defined as a section heading, but I couldn't find a way to force the numbering to show up either.
Any help is appreciated! Thanks!
- If it hasn't been stated yet, the answer is (for wiki markup, at least): no. --184.108.40.206 00:56, 31 January 2013 (UTC)
Multi-column lists don't work in IE
- I think that the question is good but no answer. Maybe a well-known issue which is described somewhere else ? In this case, it would be nice to help and tell where. Best regards, Jatayou 15:11, 19 September 2008 (UTC)
help!!! i cant create a deeper level list!!!
In my wiki, i put two stars in a new line like this:
- some text
and i get two dots instead of a deeper level dot!!
Try this instead.
The colon indents the paragraph and the asterisk yields a bullet. (Najevi 12:47, 11 May 2008 (UTC))
The HTML <li value="..."> syntax may be combined with the wikicode # markup
From the help page:
"The HTML <li value="..."> syntax may be combined with the wikicode # markup, as follows:"
#<li value=10>Saint Petersburg #Petrograd #Leningrad
On my MediaWiki (1.14) this is rendering like this, with an empty 1st element:
1. 10. Saint Petersberg 11. Petrograd 12. Leningrad
Is there a hidden setting somewhere to get this to work correctly? The rendered HTML from my site:
<ol><li><li value="10">Saint Petersburg </li><li>Petrograd </li><li>Leningrad </li></ol>
Compared to on this site:
<ol> <li value="10">Saint Petersburg</li> <li>Petrograd</li> <li>Leningrad</li> </ol>
Besides being much neater on this site, it's accurate. Thanks.
- The syntax is nice, the layout cool - and it doesn't work for me neither :-( (Mediawiki 1.13 & 1.11). Any hints? Is it really just 1.15alpha ???
I want to continue at the correct indent after having inserted a list
I want to have something like this
1. main1 2. main2 * item1 * item2 * item3 continue at the indent of main2 (this is the important line!!!) 3. main3
How can I do this? If I use #: then the indent is too large!
- It was written above.
- Please edit to see the solution. JackPotte 17:21, 5 April 2011 (UTC)
Thank you, JackPotte, this would be a solution. Unfortunately I have the same problem as described just above my entry. When I'm using something like #<li value="4">, then a useless line with a "1." is generated. So it's no solution for me. 08:50, 6 April 2011 (UTC)
Badly needed overhaul
I've completely overhauled en.wikipedia's version of this. It contained there, and still contains here, a surprisingly large amount of bad advice, with a lot of good advice missing, and a lot of palimpsestuous sloppy writing and coding. The cleaned up version is here: http://en.wikipedia.org/w/index.php?title=Help:List&oldid=455796594 (This may be one of the pages at en.wikipedia that is regularly overwritten with the en.meta version, so I'm linking to the diff.)
In particular, I've updated the document to reflect present standards and expectations about them, because much of the older text appeared to reflect a 1996-ish "It looks okay in my browser, so just do it, and to hell with accessibility, usability, portability, validity, machine parseability, etc." attitude. Some of it was just downright daft, like using fixed cm instead of flexible em units, talking about user style CSS directives when we're supposed to be talking about wiki code, including redundant examples, recommending outright abuse of semantic markup for purely stylist reasons as if CSS had never been invented, talking in Wikipedian jargon that many Help:foo readers wouldn't understand, and many other "sins". Did lots of basic copy-editing for readability, too.
I edit Meta so infrequently, I'm not sure how bold people usually are around here, so I'll let regulars look this over and see if they want to import the changes (or drop me a line and encourage me to do so). I don't want to work for several hours on overhauling the copy here (lots of templates needs replacing or substituting, etc. from the WP version - I can't just copy-paste it), only to have someone blanket revert me. — SMcCandlish [talk] [cont] ‹(-¿-)› 04:52, 16 October 2011 (UTC)
PS: There's more coming, too. As many of you probably know, the bullets and numbers that are auto-generated by lists are not considered content in most browsers, and are not copy-pastable as a result. This is stupid and probably the #1 most annoying usability problem that is still lingering from the days of the invention of HTML, but it's there. I'm working on a workaround for this at en.wikipedia as we e-speak. Generally we don't care in talk pages and policy pages, but it's a very serious usability and re-usability issue for article content. — SMcCandlish [talk] [cont] ‹(-¿-)› 04:55, 16 October 2011 (UTC)
changing glyph used for unordered lists
I can't find in the documentation how to change the glyph used for unordered lists. I would like an unchecked box and a checked box intermixed in an unordered list so that I can track which items in the list have been resolved and which are open. Somehow in the help sections for unordered lists I can't find the needed information. I am sure I am missing something simple.
- Looks like MediaWiki clobbers inline CSS for setting unordered list symbol type:
<ul style="list-style-type:square; margin-left:48px;"> <li>Stuff</li> <li>More stuff</li> </ul>
- More stuff
- So sad. Maybe you can do it with a style-sheet, but overriding inline CSS is pretty ultra-lame. A dirty little secret apparently. --220.127.116.11 01:09, 31 January 2013 (UTC)
bugzilla:12262 has changed the indentation, no idea of how this matters for this page. Statistics candies: as of 20110901 en.wiki had 1005674
: below a bullet point in all pages, en.wikt 2681 in articles. Found out with a stupid grepping:
$ grep -B 1 "^:" enwiki-20110901-pages-meta-current.xml | grep -c "^\*". Nemo 21:30, 11 March 2012 (UTC)
continuing list after a preformatted text
Hello, I have this problem on my wiki : some of my lists contains preformatted elements, and that seems to break the list. Here is an example
*item 1 *item 2 **example (these are lines from an entry file for a script, but it doen't matter) texttexttexttexttexttext text2text2text2text2text2 **2nd example texttexttexttexttext text2text2text2text2
- item 1
- item 2
- example (these are lines from an entry file for a script, but it doen't matter)
- 2nd example
Notice how the list is broken.
I don't know how to correct that. I have tried using ":*", with <pre> tag, but it breaks the preformatted text. Is there a way to unbreak the list ?
Simple templates for multi-column lists
I've created a new h2 section, Multi-column lists, as an umbrella over Multi-column bulleted list and Multi-column numbered list (both demoted to h3). It starts with links to the three Col-... templates. --Thnidu (talk) 22:53, 2 April 2013 (UTC)
Colon in text creates new item
I ran into this issue:
I like to create a line as in
One: The first subject
When I code
;One: The first subject
I'd like to have the definition list item to contain a colon, but it creates a definition description in stead.
- The first subject
When I do it the other way around it renders correctly:
- Subitem; more than just a word
Is this 'normal behavior', 'as is' or just a bug?
List-agnostic markup insertions
My question is closely related to bugzilla:1115, but I hope there is some trick that I'm missing. I'm trying (bugzilla:58429) to automatically insert some markup (specifically, to apply a CSS class) around some text in a consistent way. Lists pose two conflicting problems with newlines:
- the position of markup respective to the preceding newline is significant, in fact whatever I prepend to a bullet or # etc., even if invisible, makes the bullet not start a list
- the presence of a newline ends a list item.
For (1), to prepend some markup to some text I must add a newline or I may "escape" some list items etc.; but for (2), when such text is in the middle of a line, by adding a newline I close a list item. Maybe Patrick, Gwicke or Cscott would know? --Nemo 15:03, 16 March 2014 (UTC)
- Well, one option is to replace '#' at the start of the line with <my mark up><li>. That is, replace the '#' with a '
- '. Then you don't need to add a newline, so you don't trigger (2). But you do need to know if the thing you are marking up is at the start of the line.
- A better solution is to do the transformation on the Parsoid DOM markup, as shown in https://doc.wikimedia.org/Parsoid/master/#!/guide/jsapi -- then you can just add your class (or other markup) and let Parsoid worry about serializing it correctly. Much easier! Cscott (talk) 15:21, 16 September 2015 (UTC)