Help:段落编辑

Cnic.org,开放的网络天书!

页面可以分成许多的段落使用段落标题语法进行编辑。

目录

产生段落

可以用标题来产生段落,请看下面的代码,另请参看help:如何编辑页面

==段落标题==
===子标题===
====子标题的子标题====


目录(TOC)

每篇文章只要段落标题超过三个,就会自动根据这些标题生成一个目录(table of contents)(TOC),下面的情况不会出现目录:

  • 用户在参数设置中关闭了相应的设置
  • 在文章中加入了__NOTOC__ 代码

使用__FORCETOC__ 或 __TOC__ 代码可以在少于四个段落标题的情况下强制显示目录。

目录会自动放在第一个标题的前面,或者放在 __TOC__代码的地方。 因此在目录前写一些介绍性的文字是一个好主意,这有助于“提前”了解相关主题。Although usually a header after the TOC is preferable, __TOC__ can be used to avoid being forced to insert a meaningless header just to position the TOC correctly, i.e., not too low.

在参数设置中可以设置对标题进行自动编号。

help:template名字空间中的段落标题不会出现在目录中。The automatic section numbering restarts with 1 at the beginning of a template, and continues with the section numbering of the referring page itself after the template.

Compact TOC

Where you have a large number of very short headings (such as letters of the alphabet) you can get a very long table of contents. An alternative is a compact TOC, which you can achieve by inserting the following text:

{{compactTOC}}

which looks like this:

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

You can do similar things with years or decades e.g.

1900s - 1910s - 1920s - 1930s - 1940s - 1950s - 1960s - 1970s - 1980s - 1990s - 2000s

Both of the above make use of section linking, see below.

段落链接

在目录中的每个标题都有一个链接,可以直接跳转到相应的段落。

你可以在本页中使用[[ #标题名称 | 文字 ]], 或者链接其他页面[[ 页面名称#标题 | 文字 ]]。

你可以使用help:跨语言链接连接到其他语言的段落。也可以使用重定向功能。

段落的编辑

你可以多个别的段落使用“段落编辑功能”,在每个段落标题的右侧都有一个“[编辑]”链接。它可以用来只编辑当前这个段落的内容。

使用"__NOEDITSECTION__" 可以禁止段落编辑。

Opening a link in a header in a new window

When right click editing is enabled, you cannot right click a link in a header to open it in a new window, etc. However most browsers have an alternative way of doing that (Mozilla: middle click, ctrl+left click, type ahead find, TAB navigation; IE: shift+left click).

Horizontal dividing line

A horizontal dividing line as a division demarcation is not taken into account in the section numbering and TOC. Therefore it should not be used for dividing a page in sets of sections.

"See also" line or section

If a page consists of sections and a "see also" refers to the whole page, then make it a separate section. This is to avoid it becoming part of the prior section, to make it visible in the TOC, and to make it easily accessible through the TOC.

Alternatively, a "see also" line is sometimes put at the beginning.

A "see also" belonging to just one section can be put in that section: within a paragraph, as a separate paragraph, or as a subsection.

Large text that should not begin a section

When using large text that should not begin a section, e.g. to show a font, use something like

<b><font style="font-size:120%"> Example text </font></b>

giving

Example text

个人工具
天书
中文维客年会
网络天书
pagerank 5/10