差别
这里会显示出您选择的修订版和当前版本之间的差别。
| 两侧同时换到之前的修订记录前一修订版后一修订版 | 前一修订版 | ||
| wiki:syntax [2022/09/29 10:19] – 增加danger格式的描述…… Seb | wiki:syntax [2025/07/27 20:26] (当前版本) – 外部编辑 127.0.0.1 | ||
|---|---|---|---|
| 行 1: | 行 1: | ||
| - | ====== | + | ====== |
| - | [[doku> | + | [[doku> |
| - | ===== 基本文本格式 | + | ===== Basic Text Formatting |
| - | DokuWiki | + | DokuWiki |
| - | DokuWiki支持 | + | DokuWiki |
| - | | + | |
| - | 可以使用 | + | You can use <sub>subscript</ |
| - | | + | |
| - | 您也可以使用 | + | You can mark something as <del>deleted</ |
| - | | + | |
| - | + | ||
| - | 把< | + | |
| - | 把< | + | **Paragraphs** are created from blank lines. If you want to **force a newline** without a paragraph, you can use two backslashes followed by a whitespace or the end of line. |
| - | + | ||
| - | 此外,wiki支持通过一定的格式,来高亮文本,例如: | + | |
| - | <wrap warning> | + | This is some text with some linebreaks\\ Note that the |
| - | <wrap danger> | + | two backslashes are only recognized at the end of a line\\ |
| - | <wrap info> | + | or followed by\\ a whitespace |
| - | <wrap tip> | + | |
| - | <wrap important> | + | |
| - | <wrap help> | + | |
| - | <wrap download> | + | |
| - | <wrap todo> | + | |
| - | <wrap em> | + | |
| - | <wrap hi> | + | |
| - | <wrap lo> | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | <wrap tip> | + | |
| - | <wrap important> | + | |
| - | <wrap help> | + | |
| - | <wrap download> | + | |
| - | <wrap todo> | + | |
| - | <wrap em> | + | |
| - | <wrap hi> | + | |
| - | <wrap lo> | + | |
| + | You should use forced newlines only if really needed. | ||
| - | ---- | + | ===== Links ===== |
| - | **段落** 是由空行所建立的。如果您想 **强制建立新行** 而不建立段落,您可以使用两个连续的反斜杠+空格或是回车作为标记。请看样例: | + | DokuWiki supports multiple ways of creating links. |
| - | 这是一些有着换行标记的文字。\\ 请注意 | + | ==== External ==== |
| - | 反斜杠只在回车符之前\\ | + | |
| - | 或者在\\ 一个空格之前的时候才有效。 \\而这样就并不起作用。 | + | |
| - | 这是一些有着换行标记的文字。\\ 请注意 | + | External links are recognized automagically: |
| - | 反斜杠只在回车符之前\\ | + | |
| - | 或者在\\ 一个空格之前的时候才有效。 \\而这样就并不起作用。 | + | |
| - | 请只在必须的时候才使用强制的换行标记。 | + | DokuWiki supports multiple ways of creating links. External links are recognized |
| + | automagically: | ||
| + | link text as well: [[http:// | ||
| + | addresses like this one: < | ||
| - | ===== 插入文本框 ===== | + | ==== Internal |
| - | 希望像word文档一样,在页面里插入文本框?可以做到!就像这样: | + | Internal links are created by using square brackets. You can either just give a [[pagename]] or use an additional [[pagename|link text]]. |
| - | < | + | Internal links are created by using square brackets. You can either just give |
| - | 文本框 | + | a [[pagename]] or use an additional [[pagename|link text]]. |
| - | </ | + | |
| - | < | + | [[doku>pagename|Wiki pagenames]] are converted to lowercase automatically, |
| - | 文本框 | + | |
| - | </well> | + | |
| - | ---- | + | You can use [[some: |
| - | 也许你希望某个文本框更加引人注目,那么不妨试试这个格式: | + | You can use [[some: |
| - | <alert type=" | + | For details about namespaces see [[doku>namespaces]]. |
| - | <alert type=" | + | |
| - | <alert type=" | + | |
| - | <alert type=" | + | |
| - | <alert type=" | + | Linking to a specific section is possible, too. Just add the section name behind a hash character as known from HTML. This links to [[syntax# |
| - | <alert type=" | + | |
| - | <alert type=" | + | |
| - | <alert type=" | + | |
| - | ---- | + | This links to [[syntax# |
| - | 也可以使用这种带有标志的圆角文本框。 | + | Notes: |
| - | <WRAP round warning> | + | * Links to [[syntax|existing pages]] are shown in a different style from [[nonexisting]] ones. |
| - | 警告-圆角文本框 | + | * DokuWiki does not use [[wp>CamelCase]] to automatically create links by default, but this behavior can be enabled in the [[doku>config]] file. Hint: If DokuWiki is a link, then it's enabled. |
| - | </WRAP> | + | * When a section' |
| - | <WRAP round danger> | + | |
| - | 危险-圆角文本框 | + | |
| - | </ | + | |
| - | <WRAP round info> | + | |
| - | 消息-圆角文本框 | + | |
| - | </ | + | |
| - | <WRAP round tip> | + | |
| - | 提示-圆角文本框 | + | |
| - | </ | + | |
| - | <WRAP round important> | + | |
| - | 重要信息-圆角文本框 | + | |
| - | </ | + | |
| - | <WRAP round help> | + | |
| - | 帮助-圆角文本框 | + | |
| - | </ | + | |
| - | <WRAP round download> | + | |
| - | 下载-圆角文本框 | + | |
| - | </ | + | |
| - | <WRAP round todo> | + | |
| - | 待办事项-圆角文本框 | + | |
| - | </ | + | |
| + | ==== Interwiki ==== | ||
| + | DokuWiki supports [[doku> | ||
| - | | + | |
| - | | + | |
| - | </ | + | |
| - | <WRAP round danger> | + | |
| - | 危险-圆角文本框 | + | |
| - | </ | + | |
| - | <WRAP round info> | + | |
| - | 消息-圆角文本框 | + | |
| - | </ | + | |
| - | <WRAP round tip> | + | |
| - | 提示-圆角文本框 | + | |
| - | </ | + | |
| - | <WRAP round important> | + | |
| - | 重要信息-圆角文本框 | + | |
| - | </ | + | |
| - | <WRAP round help> | + | |
| - | 帮助-圆角文本框 | + | |
| - | </ | + | |
| - | <WRAP round download> | + | |
| - | 下载-圆角文本框 | + | |
| - | </ | + | |
| - | <WRAP round todo> | + | |
| - | 待办事项-圆角文本框 | + | |
| - | </WRAP> | + | |
| - | 这类圆角文本框的对齐格式、宽度是可调的,例如: | + | ==== Windows Shares ==== |
| - | <WRAP center round info 50%> | + | Windows shares like [[\\server\share|this]] are recognized, too. Please note that these only make sense in a homogeneous user group like a corporate [[wp>Intranet]]. |
| - | 这是一个50%宽度,居中对齐的圆角文本框! | + | |
| - | </WRAP> | + | |
| - | | + | |
| - | 这是一个50%宽度,居中对齐的圆角文本框! | + | |
| - | </ | + | |
| - | ---- | + | Notes: |
| - | 或者是这种插入栏,它包含标题、正文以及标志。 | + | * For security reasons direct browsing of windows shares only works in Microsoft Internet Explorer per default (and only in the "local zone" |
| + | * For Mozilla and Firefox it can be enabled through different workaround mentioned in the [[http:// | ||
| + | <?php | ||
| + | /** | ||
| + | * Customization of the english language file | ||
| + | * Copy only the strings that needs to be modified | ||
| + | */ | ||
| + | $lang[' | ||
| + | </ | ||
| - | <callout type=" | + | ==== Image Links ==== |
| - | 成功标志插入栏-正文 | + | |
| - | </ | + | |
| - | <callout type=" | + | |
| - | 消息标志插入栏-正文 | + | |
| - | </ | + | |
| - | <callout type=" | + | |
| - | 警告标志插入栏-正文 | + | |
| - | </ | + | |
| - | <callout type=" | + | |
| - | 提示标志插入栏-正文 | + | |
| - | </ | + | |
| - | <callout type=" | + | |
| - | 危险标志插入栏-正文 | + | |
| - | </ | + | |
| - | <callout type=" | + | You can also use an image to link to another internal or external page by combining the syntax for links and [[# |
| - | 成功标志插入栏-正文 | + | |
| - | </ | + | |
| - | <callout type=" | + | |
| - | 消息标志插入栏-正文 | + | |
| - | </ | + | |
| - | <callout type=" | + | |
| - | 警告标志插入栏-正文 | + | |
| - | </ | + | |
| - | <callout type=" | + | |
| - | 提示标志插入栏-正文 | + | |
| - | </ | + | |
| - | <callout type=" | + | |
| - | 危险标志插入栏-正文 | + | |
| - | </ | + | |
| - | + | ||
| - | 当然,这种插入栏的标题、图标都是可以取消掉的: | + | |
| - | < | + | |
| - | 一个不带标志、也没有标题的插入栏 | + | |
| - | </ | + | |
| - | + | ||
| - | < | + | |
| - | 一个不带标志、也没有标题的插入栏 | + | |
| - | </ | + | |
| - | + | ||
| - | ---- | + | |
| - | + | ||
| - | 还也可以用这个文字板样式,此样式支持添加标题: | + | |
| - | + | ||
| - | <panel title=" | + | |
| - | 文字板内容 | + | |
| - | </ | + | |
| - | + | ||
| - | <panel type=" | + | |
| - | 消息文字板内容 | + | |
| - | </ | + | |
| - | + | ||
| - | <panel type=" | + | |
| - | 成功文字板内容 | + | |
| - | </ | + | |
| - | + | ||
| - | <panel type=" | + | |
| - | 警告文字板内容 | + | |
| - | </ | + | |
| - | + | ||
| - | <panel type=" | + | |
| - | 危险文字板内容 | + | |
| - | </ | + | |
| - | + | ||
| - | <panel title=" | + | |
| - | 文字板内容 | + | |
| - | </ | + | |
| - | <panel type=" | + | |
| - | 消息文字板内容 | + | |
| - | </ | + | |
| - | <panel type=" | + | |
| - | 成功文字板内容 | + | |
| - | </ | + | |
| - | <panel type=" | + | |
| - | 警告文字板内容 | + | |
| - | </ | + | |
| - | <panel type=" | + | |
| - | 危险文字板内容 | + | |
| - | </ | + | |
| - | + | ||
| - | 只需稍加修改,这个样式的文本框就可以做到折叠与展开。(点击文本框标题可以展开,再点击一下标题可以折叠) | + | |
| - | + | ||
| - | < | + | |
| - | <panel type=" | + | |
| - | 可折叠文字板内容 | + | |
| - | </ | + | |
| - | </ | + | |
| - | + | ||
| - | < | + | |
| - | <panel type=" | + | |
| - | 可折叠文字板内容 | + | |
| - | </ | + | |
| - | </ | + | |
| - | + | ||
| - | ---- | + | |
| - | + | ||
| - | ===== 链接 ===== | + | |
| - | + | ||
| - | DokuWiki 支持多种形式的链接。 | + | |
| - | + | ||
| - | ==== 外部链接 ==== | + | |
| - | + | ||
| - | 外部链接会被自动地识别:http:// | + | |
| - | + | ||
| - | DokuWiki支持多种形式的链接。外部链接会被自动地识别: | + | |
| - | http:// | + | |
| - | - 当然您也可以为链接设置名字: [[http:// | + | |
| - | 类似这样的电子邮件地址: < | + | |
| - | + | ||
| - | ==== 内部链接 ==== | + | |
| - | + | ||
| - | 内部链接可以用方括号创建。您可以只给出链接的地址:[[pagename]],也可以附加上链接的名字:[[pagename|我的链接]]。 | + | |
| - | + | ||
| - | 内部链接可以用方括号创建。您可以只给出链接的地址:[[pagename]], | + | |
| - | 也可以附加上链接的名字:[[pagename|我的链接]]。 | + | |
| - | + | ||
| - | [[doku> | + | |
| - | + | ||
| - | 您可以通过在页面名中使用冒号的方式来使用 [[wiki: | + | |
| - | + | ||
| - | 您可以通过在页面名中使用冒号的方式来使用 [[wiki: | + | |
| - | + | ||
| - | 如果您需要关于命名空间(namespaces)的更详细的信息,请参见 [[doku> | + | |
| - | + | ||
| - | 您也可以链接到一个网页内部的某一节,只需要将该节书签的名称以一个# | + | |
| - | + | ||
| - | 这是一个连向 [[syntax# | + | |
| - | + | ||
| - | 注: | + | |
| - | + | ||
| - | * 到 [[syntax|已存在页面]] 的链接和到 [[nonexisting|未存在页面]] 的链接,其外观是不同的。 | + | |
| - | * 默认情况下,DokuWiki 不使用[[wp> | + | |
| - | * 当一节的标题改变时,该节的书签也会改变,因此,请不要太依赖页面内的链接。 | + | |
| - | + | ||
| - | ==== 图像链接 ==== | + | |
| - | + | ||
| - | 您也可以用图像来作为一个内部或者外部的链接,只需同时使用链接和[[# | + | |
| - | + | ||
| - | | + | |
| [[http:// | [[http:// | ||
| - | 请注意:在链接名中使用语法,只有显示图像的语法会被识别,请不要使用其它语法。 | + | Please note: The image formatting is the only formatting syntax accepted in link names. |
| - | DokuWiki 支持完整的[[# | + | The whole [[# |
| + | ===== Footnotes ===== | ||
| - | ===== 脚注 ===== | + | You can add footnotes ((This is a footnote)) by using double parentheses. |
| - | 您可以使用两个连续小括号来添加脚注((看这里,这是一个脚注))。 | + | You can add footnotes |
| - | 您可以使用两个连续小括号来添加脚注((看这里,这是一个脚注))。 | + | ===== Sectioning ===== |
| - | ===== 标题段落 ===== | + | You can use up to five different levels of headlines to structure your content. If you have more than three headlines, a table of contents is generated automatically -- this can be disabled by including the string ''< |
| - | 您可以使用最多达5层的标题来使您的页面更富结构性。如果您使用了三个以上的标题,那么 DokuWiki 会自动在页面上生成一个名为“本页目录”的标题列表。当然,您也可以关闭这项特性,只需在编辑时在页面里加入 ''< | + | ==== Headline Level 3 ==== |
| + | === Headline Level 4 === | ||
| + | == Headline Level 5 == | ||
| - | ==== H3标题 | + | |
| - | === H4标题 | + | === Headline Level 4 === |
| - | == H5标题 | + | == Headline Level 5 == |
| - | ==== H3标题 ==== | + | By using four or more dashes, you can make a horizontal line: |
| - | === H4标题 === | + | |
| - | == H5标题 == | + | |
| - | + | ||
| - | 您可以通过连续的4个以上“-”号来创建一条水平分割线: | + | |
| ---- | ---- | ||
| - | 只是单纯想创建一个大字号的标题,可以下述这个样式,这样的标题不会被收录到“本页目录里”: | + | ===== Media Files ===== |
| - | < | + | You can include external and internal [[doku>images|images, |
| - | < | + | Real size: {{wiki: |
| - | ===== 分栏 ===== | + | Resize to given width: |
| - | 合理的布局会让你的页面更加美观,为此你可以试一试分栏功能:\\ | + | |
| - | \\ | + | |
| - | <WRAP group> | + | Resize to given width and height((when the aspect ratio of the given width and height doesn' |
| - | <WRAP half column> | + | |
| - | 这个语法可以实现分栏功能,我来组成左半栏。 | + | |
| - | </ | + | |
| - | <WRAP half column> | + | |
| - | 我来组成右半栏! | + | |
| - | </ | + | |
| - | <WRAP group> | + | Resized external image: {{https://www.php.net/ |
| - | <WRAP half column> | + | |
| - | 这个语法可以实现分栏功能,我来组成左半栏。 | + | |
| - | </WRAP> | + | |
| - | <WRAP half column> | + | |
| - | 我来组成右半栏! | + | |
| - | </WRAP> | + | |
| - | ---- | + | Real size: {{wiki: |
| + | Resize to given width: | ||
| + | Resize to given width and height: {{wiki: | ||
| + | Resized external image: {{https:// | ||
| - | 分成更多栏、在栏内嵌套其他语法,都是可以实现的,例如: | ||
| - | <WRAP group> | + | By using left or right whitespaces you can choose the alignment. |
| - | <WRAP third column> | + | |
| - | 第一栏。 | + | |
| - | </ | + | |
| - | <WRAP third column> | + | |
| - | < | + | |
| - | 第二栏,包括文本和图像: | + | |
| - | {{wiki: | + | |
| - | </ | + | |
| - | </ | + | |
| - | <WRAP third column> | + | |
| - | <WRAP round tip> | + | |
| - | 第三栏,嵌入一个圆角文本框语法。 | + | |
| - | </ | + | |
| - | </ | + | |
| - | + | ||
| - | <WRAP group> | + | |
| - | <WRAP third column> | + | |
| - | 第一栏。 | + | |
| - | </ | + | |
| - | <WRAP third column> | + | |
| - | < | + | |
| - | 第二栏,包括文本和图像: | + | |
| - | {{wiki: | + | |
| - | </ | + | |
| - | </ | + | |
| - | <WRAP third column> | + | |
| - | <WRAP round tip> | + | |
| - | 第三栏,嵌入一个圆角文本框语法。 | + | |
| - | </ | + | |
| - | </ | + | |
| - | + | ||
| - | 可以在沙箱里尽情尝试! | + | |
| - | + | ||
| - | ===== 图像和其它文件 ===== | + | |
| - | + | ||
| - | 您可以使用双大括号来在页面中加入 [[doku> | + | |
| - | + | ||
| - | 原始大小: | + | |
| - | + | ||
| - | 指定宽度(50 pixel): | + | |
| - | + | ||
| - | 指定宽度和高度(200×50)((若指定宽高比例不合适,图像将被裁减)): | + | |
| - | + | ||
| - | 重新指定宽度和高度的外部图像(100x100): | + | |
| - | + | ||
| - | 原始大小: | + | |
| - | 指定宽度(50 pixel): | + | |
| - | 指定宽度和高度(200×50): | + | |
| - | 重新指定宽度和高度的外部图像(100x100): | + | |
| - | + | ||
| - | + | ||
| - | 使用左方或者右方的空格,您可以选择对齐方式: | + | |
| {{ wiki: | {{ wiki: | ||
| 行 424: | 行 157: | ||
| {{ wiki: | {{ wiki: | ||
| - | 当然,您也可以指定一个图像的名字,将鼠标移到图像上可以看到效果。 | + | Of course, you can add a title (displayed as a tooltip by most browsers), too. |
| - | {{ wiki: | + | {{ wiki: |
| - | {{ wiki: | + | {{ wiki: |
| - | 如果您指定的文件名(无论是外部的还是内部的)不是一个图像'' | + | For linking an image to another page see [[#Image Links]] above. |
| - | ==== 支持的媒体格式 | + | ==== Supported Media Formats |
| - | DokuWiki | + | DokuWiki |
| - | | 图像 | + | | Image | '' |
| - | | 视频 | + | | Video | '' |
| - | | 音频 | + | | Audio | '' |
| | Flash | '' | | Flash | '' | ||
| - | 如果指定不支持的媒体格式的文件名,则它将作为链接显示。 | + | If you specify a filename that is not a supported media format, then it will be displayed as a link instead. |
| - | 加上 | + | By adding |
| {{wiki: | {{wiki: | ||
| - | {{wiki: | + | {{wiki: |
| - | ===== 列表 ===== | + | ==== Fallback Formats |
| - | Dokuwiki 支持带编号或不带编号的列表。要使用列表,在文字前加入两个空格,然后使用'' | + | Unfortunately not all browsers understand all video and audio formats. To mitigate the problem, you can upload your file in different formats for maximum browser compatibility. |
| - | * 列表 | + | For example consider this embedded mp4 video: |
| - | * 第二项 | + | |
| - | * 下一层 | + | |
| - | * 第三项 | + | |
| - | - 带编号的列表 | + | |
| - | - 第二项 | + | |
| - | - 用缩进表示更深的层 | + | When you upload a '' |
| - | - 完了 | + | |
| + | Additionally DokuWiki supports a " | ||
| + | |||
| + | ===== Lists ===== | ||
| + | |||
| + | Dokuwiki supports ordered and unordered lists. To create a list item, indent your text by two spaces and use a '' | ||
| + | |||
| + | * This is a list | ||
| + | * The second item | ||
| + | * You may have different levels | ||
| + | * Another item | ||
| + | |||
| + | | ||
| + | - Another item | ||
| + | - Just use indention for deeper levels | ||
| + | - That's it | ||
| < | < | ||
| - | * 列表 | + | |
| - | * 第二项 | + | * The second item |
| - | * 下一层 | + | * You may have different levels |
| - | * 第三项 | + | * Another item |
| - | - 带编号的列表 | + | - The same list but ordered |
| - | - 第二项 | + | - Another item |
| - | - 用缩进表示更深的层 | + | - Just use indention for deeper levels |
| - | - 完了 | + | - That's it |
| </ | </ | ||
| - | 同时可以关注 | + | Also take a look at the [[doku> |
| + | |||
| + | ===== Text Conversions ===== | ||
| - | ===== 文本转换 ===== | + | DokuWiki can convert certain pre-defined characters or strings into images or other text or HTML. |
| - | DokuWiki 可以将预定义的字符或者字符串转换成图片、其他文本或 | + | The text to image conversion is mainly done for smileys. And the text to HTML conversion is used for typography replacements, |
| - | 文本到图片的转换,主要用作表情符号。文本到 HTML 的转换,多用於显示符号替换,但也可以配置为使用其他 HTML。 | + | ==== Text to Image Conversions |
| - | ==== 表情符号 | + | |
| - | DokuWiki | + | DokuWiki |
| * 8-) %% 8-) %% | * 8-) %% 8-) %% | ||
| 行 501: | 行 247: | ||
| * ;-) %% ;-) %% | * ;-) %% ;-) %% | ||
| * ^_^ %% ^_^ %% | * ^_^ %% ^_^ %% | ||
| + | * m( %% m( %% | ||
| * :?: %% :?: %% | * :?: %% :?: %% | ||
| * :!: %% :!: %% | * :!: %% :!: %% | ||
| 行 507: | 行 254: | ||
| * DELETEME %% DELETEME %% | * DELETEME %% DELETEME %% | ||
| - | ==== 印刷样式 | + | ==== Text to HTML Conversions |
| - | [[DokuWiki]] | + | Typography: |
| -> <- <-> => <= <=> >> << -- --- 640x480 (c) (tm) (r) | -> <- <-> => <= <=> >> << -- --- 640x480 (c) (tm) (r) | ||
| 行 519: | 行 266: | ||
| </ | </ | ||
| - | 请注意:在配置文件中可以禁用这类自动转换。 | + | The same can be done to produce any kind of HTML, it just needs to be added to the [[doku> |
| - | ===== 层次显示 ===== | + | There are three exceptions which do not come from that pattern file: multiplication entity (640x480), ' |
| - | 有时候(特别是讨论时)您想把某些文字(尤为各次的回复)标示作不同的层次,您可以使用下列的语法: | + | ===== Quoting ===== |
| + | |||
| + | Some times you want to mark some text to show it's a reply or comment. You can use the following syntax: | ||
| < | < | ||
| - | 我认为我们应该一起行动 | + | I think we should do it |
| - | > 不行,不能一起行动 | + | > No we shouldn' |
| - | >> | + | >> |
| - | > 真的吗? | + | > Really? |
| - | >> | + | >> |
| - | >>> | + | >>> |
| </ | </ | ||
| - | 我认为我们应该一起行动 | ||
| - | > 不行,不能一起行动 | + | I think we should do it |
| - | >> 嗯……,我感觉能行 | + | > No we shouldn' |
| - | > 真的吗? | + | >> Well, I say we should |
| - | >> 是! | + | > Really? |
| - | >>> 那么,一起行动吧! | + | >> |
| - | ===== 表格 ===== | + | >>> |
| - | DokuWiki 可以用简单的语法创建表格。 | + | ===== Tables ===== |
| - | ^ 标题 1 ^ 标题 2 ^ 标题 3 ^ | + | DokuWiki supports a simple syntax to create tables. |
| - | | (1,1) | + | |
| - | | (2,1) | + | |
| - | | (3,1) | + | |
| - | 表格的每一行都以分隔符 '' | + | ^ Heading 1 ^ Heading 2 ^ Heading 3 ^ |
| + | | Row 1 Col 1 | Row 1 Col 2 | Row 1 Col 3 | | ||
| + | | Row 2 Col 1 | some colspan (note the double pipe) || | ||
| + | | Row 3 Col 1 | Row 3 Col 2 | Row 3 Col 3 | | ||
| - | | + | Table rows have to start and end with a '' |
| - | | (1,1) | + | |
| - | | (2,1) | + | |
| - | | (3,1) | + | |
| - | 要水平合并单元格,只需要将后一个单元格设置为空即可,如上面演示的一样。请确保每一行有相同数量的单元格分隔符! | + | ^ Heading 1 ^ Heading 2 ^ Heading 3 ^ |
| + | | Row 1 Col 1 | Row 1 Col 2 | Row 1 Col 3 | | ||
| + | | Row 2 Col 1 | some colspan (note the double pipe) || | ||
| + | | Row 3 Col 1 | Row 3 Col 2 | Row 3 Col 3 | | ||
| - | 竖直的标题列也是可以实现的: | + | To connect cells horizontally, |
| - | | ^ 标题 1 ^ 标题 2 ^ | + | Vertical tableheaders are possible, too. |
| - | ^ 标题 3 | (1,2) | + | |
| - | ^ 标题 4 | 不再合并单元格 | | | + | |
| - | ^ 标题 5 | (2,2) | + | |
| - | 可以看到,单元格前面的分隔符决定了单元格的格式。 | + | | ^ Heading 1 ^ Heading 2 ^ |
| + | ^ Heading 3 | Row 1 Col 2 | Row 1 Col 3 | | ||
| + | ^ Heading 4 | no colspan this time | | | ||
| + | ^ Heading 5 | Row 2 Col 2 | Row 2 Col 3 | | ||
| - | | ^ 标题 1 ^ 标题 2 ^ | + | As you can see, it's the cell separator before a cell which decides about the formatting: |
| - | ^ 标题 3 | (1,2) | + | |
| - | ^ 标题 4 | 不再合并单元格 | | | + | |
| - | ^ 标题 5 | (2,2) | + | |
| - | 您也可以垂直合并两格或多格。只要在下面的格内输入'':::'' | + | | |
| - | ^ 标题 | + | ^ Heading 3 |
| - | | (1,1) | + | ^ Heading 4 |
| - | | (2,1) | + | ^ Heading 5 |
| - | | (3,1) | + | |
| - | 除跨行合并语法'':::'' | + | You can have rowspans (vertically connected cells) by adding |
| - | | + | ^ Heading |
| - | | (1,1) | 这次示范垂直合并 | + | | Row 1 Col 1 | this cell spans vertically |
| - | | (2,1) | ::: | (2,3) | | + | | Row 2 Col 1 | ::: | Row 2 Col 3 | |
| - | | (3,1) | ::: | (3,3) | | + | | Row 3 Col 1 | ::: | Row 2 Col 3 | |
| - | 您可以对齐表格的文字。只需要添加多余两个的空格在您需要对齐的方向的反向即可:如果需要右对齐,在左边添加两个空格;反之,则在右边添加。在两边均添加空格可以实现中间对齐。 | + | Apart from the rowspan syntax those cells should not contain anything else. |
| - | ^ 有对齐的表格 | + | ^ Heading 1 ^ Heading 2 ^ Heading 3 ^ |
| - | | 右对齐| | + | | Row 1 Col 1 | this cell spans vertically | Row 1 Col 3 | |
| - | |左对齐 | + | | Row 2 Col 1 | ::: | Row 2 Col 3 | |
| + | | Row 3 Col 1 | ::: | Row 2 Col 3 | | ||
| + | |||
| + | You can align the table contents, too. Just add at least two whitespaces at the opposite end of your text: Add two spaces on the left to align right, two spaces on the right to align left and two spaces at least at both ends for centered text. | ||
| + | |||
| + | ^ Table with alignment | ||
| + | | right| | ||
| + | |left | ||
| | xxxxxxxxxxxx | xxxxxxxxxxxx | xxxxxxxxxxxx | | | xxxxxxxxxxxx | xxxxxxxxxxxx | xxxxxxxxxxxx | | ||
| - | 下面是源文件中的格式: | + | This is how it looks in the source: |
| - | ^ 有对齐的表格 | + | ^ Table with alignment |
| - | | 右对齐| | + | | right| |
| - | |左对齐 | + | |left |
| | xxxxxxxxxxxx | xxxxxxxxxxxx | xxxxxxxxxxxx | | | xxxxxxxxxxxx | xxxxxxxxxxxx | xxxxxxxxxxxx | | ||
| - | 注意:不支持垂直对齐 | + | Note: Vertical alignment is not supported. |
| - | ===== 无格式区块 | + | ===== No Formatting |
| - | 若要略过某段内含维基语法,不对该段文字作任何处理, 可以使用 | + | If you need to display text exactly like it is typed (without any formatting), |
| < | < | ||
| - | 正如本段示范里,本来包含了网址:http:// | + | This is some text which contains addresses like this: http:// |
| </ | </ | ||
| + | The same is true for %%// | ||
| + | |||
| + | < | ||
| + | This is some text which contains addresses like this: http:// | ||
| + | </ | ||
| + | The same is true for %%// | ||
| + | |||
| + | ===== Code Blocks ===== | ||
| + | |||
| + | You can include code blocks into your documents by either indenting them by at least two spaces (like used for the previous examples) or by using the tags '' | ||
| + | |||
| + | This is text is indented by two spaces. | ||
| + | |||
| + | < | ||
| + | This is preformatted code all spaces are preserved: like <-this | ||
| + | </ | ||
| + | |||
| + | < | ||
| + | This is pretty much the same, but you could use it to show that you quoted a file. | ||
| + | </ | ||
| + | |||
| + | Those blocks were created by this source: | ||
| + | |||
| + | This is text is indented by two spaces. | ||
| + | |||
| + | < | ||
| + | This is preformatted code all spaces are preserved: like <-this | ||
| + | </ | ||
| + | |||
| + | < | ||
| + | This is pretty much the same, but you could use it to show that you quoted a file. | ||
| + | </ | ||
| + | |||
| + | ==== Syntax Highlighting ==== | ||
| + | |||
| + | [[wiki: | ||
| + | |||
| + | <code java> | ||
| + | /** | ||
| + | * The HelloWorldApp class implements an application that | ||
| + | * simply displays "Hello World!" | ||
| + | */ | ||
| + | class HelloWorldApp { | ||
| + | public static void main(String[] args) { | ||
| + | System.out.println(" | ||
| + | } | ||
| + | } | ||
| + | </ | ||
| + | |||
| + | The following language strings are currently recognized: //4cs 6502acme 6502kickass 6502tasm 68000devpac abap actionscript3 actionscript ada aimms algol68 apache applescript apt_sources arm asm asp asymptote autoconf autohotkey autoit avisynth awk bascomavr bash basic4gl batch bf biblatex bibtex blitzbasic bnf boo caddcl cadlisp ceylon cfdg cfm chaiscript chapel cil c_loadrunner clojure c_mac cmake cobol coffeescript c cpp cpp-qt cpp-winapi csharp css cuesheet c_winapi dart dcl dcpu16 dcs delphi diff div dos dot d ecmascript eiffel email epc e erlang euphoria ezt f1 falcon fo fortran freebasic freeswitch fsharp gambas gdb genero genie gettext glsl gml gnuplot go groovy gwbasic haskell haxe hicest hq9plus html html4strict html5 icon idl ini inno intercal io ispfpanel java5 java javascript jcl j jquery julia kixtart klonec klonecpp kotlin latex lb ldif lisp llvm locobasic logtalk lolcode lotusformulas lotusscript lscript lsl2 lua m68k magiksf make mapbasic mathematica matlab mercury metapost mirc mk-61 mmix modula2 modula3 mpasm mxml mysql nagios netrexx newlisp nginx nimrod nsis oberon2 objc objeck ocaml-brief ocaml octave oobas oorexx oracle11 oracle8 oxygene oz parasail parigp pascal pcre perl6 perl per pf phix php-brief php pic16 pike pixelbender pli plsql postgresql postscript povray powerbuilder powershell proftpd progress prolog properties providex purebasic pycon pys60 python qbasic qml q racket rails rbs rebol reg rexx robots roff rpmspec rsplus ruby rust sas sass scala scheme scilab scl sdlbasic smalltalk smarty spark sparql sql sshconfig standardml stonescript swift systemverilog tclegg tcl teraterm texgraph text thinbasic tsql twig typoscript unicon upc urbi uscript vala vbnet vb vbscript vedit verilog vhdl vim visualfoxpro visualprolog whitespace whois winbatch wolfram xbasic xml xojo xorg_conf xpp yaml z80 zxbasic// | ||
| + | |||
| + | There are additional [[doku> | ||
| + | |||
| + | ==== Downloadable Code Blocks ==== | ||
| + | |||
| + | When you use the '' | ||
| + | |||
| + | < | ||
| + | <file php myexample.php> | ||
| + | <?php echo "hello world!"; | ||
| + | </ | ||
| + | </ | ||
| + | |||
| + | <file php myexample.php> | ||
| + | <?php echo "hello world!"; | ||
| + | </ | ||
| + | |||
| + | If you don't want any highlighting but want a downloadable file, specify a dash ('' | ||
| + | |||
| + | ===== RSS/ATOM Feed Aggregation ===== | ||
| + | [[DokuWiki]] can integrate data from external XML feeds. For parsing the XML feeds, [[http:// | ||
| + | |||
| + | ^ Parameter | ||
| + | | any number | will be used as maximum number items to show, defaults to 8 | | ||
| + | | reverse | ||
| + | | author | ||
| + | | date | show item dates | | ||
| + | | description| show the item description. All HTML tags will be stripped | | ||
| + | | nosort | ||
| + | | //n//[dhm] | refresh period, where d=days, h=hours, m=minutes. (e.g. 12h = 12 hours). | | ||
| + | |||
| + | The refresh period defaults to 4 hours. Any value below 10 minutes will be treated as 10 minutes. [[wiki: | ||
| + | |||
| + | By default the feed will be sorted by date, newest items first. You can sort it by oldest first using the '' | ||
| + | |||
| + | **Example: | ||
| + | |||
| + | {{rss> | ||
| + | |||
| + | {{rss> | ||
| + | |||
| + | |||
| + | ===== Control Macros ===== | ||
| - | 使用百分号对 %%// | + | Some syntax influences how DokuWiki renders a page without creating any output it self. The following control macros are availble: |
| - | | + | ^ Macro ^ Description | |
| - | + | | %%~~NOTOC~~%% | |
| - | 使用百分号对 | + | | %%~~NOCACHE~~%% | DokuWiki caches all output by default. Sometimes this might not be wanted (eg. when the %%<php> |
| - | ===== 控制宏 | + | ===== Syntax Plugins |
| - | 控制宏会影响 | + | DokuWiki's syntax can be extended by [[doku> |
| - | ^ 宏 ^ 描述| | + | ~~INFO: |
| - | | %%~~NOTOC~~%% | 如果页面中出现该控制宏,将不会为该页创建目录。 | | + | |
| - | | %%~~NOCACHE~~%% | DokuWiki 默认会缓存所有的输出。有时您并不希望内容被缓存(例如您使用了上述的%%< | + | |