diff options
-rw-r--r-- | ikiwiki.mdwn | 2 | ||||
-rw-r--r-- | ikiwiki/blog.mdwn | 8 | ||||
-rw-r--r-- | ikiwiki/directive.mdwn | 39 | ||||
-rw-r--r-- | ikiwiki/formatting.mdwn | 25 | ||||
-rw-r--r-- | ikiwiki/markdown.mdwn | 6 | ||||
-rw-r--r-- | ikiwiki/pagespec/attachment.mdwn | 6 | ||||
-rw-r--r-- | ikiwiki/preprocessordirective.mdwn | 42 | ||||
-rw-r--r-- | ikiwiki/wikilink.mdwn | 6 | ||||
-rw-r--r-- | preprocessordirective.mdwn | 4 | ||||
-rw-r--r-- | shortcuts.mdwn | 4 | ||||
-rw-r--r-- | style.css | 19 | ||||
-rw-r--r-- | templates.mdwn | 2 | ||||
-rw-r--r-- | wikiicons/search-bg.gif | bin | 0 -> 74 bytes |
13 files changed, 100 insertions, 63 deletions
diff --git a/ikiwiki.mdwn b/ikiwiki.mdwn index c98a97e..89337d0 100644 --- a/ikiwiki.mdwn +++ b/ikiwiki.mdwn @@ -9,7 +9,7 @@ Some documentation on using ikiwiki: * [[ikiwiki/formatting]] * [[ikiwiki/blog]] * [[ikiwiki/pagespec]] -* [[ikiwiki/PreprocessorDirective]] +* [[ikiwiki/directive]] * [[ikiwiki/wikilink]] * [[ikiwiki/markdown]] * [[ikiwiki/subpage]] diff --git a/ikiwiki/blog.mdwn b/ikiwiki/blog.mdwn index 19ec7ac..53d4c7a 100644 --- a/ikiwiki/blog.mdwn +++ b/ikiwiki/blog.mdwn @@ -7,7 +7,7 @@ then="You can" else="If this wiki had the inline plugin enabled, you could"]] turn any page on this wiki into a weblog by using the `inline` -[[PreProcessorDirective]]. For example: +[[directive]]. For example: \[[!inline pages="blog/* and !*/Discussion" show="10" rootpage="blog"]] @@ -17,9 +17,9 @@ of them will appear in the page. Note that if files that are not pages match the [[PageSpec]], they will be included in the feed using RSS enclosures, which is useful for podcasting. -The optional `rootpage` parameter tells the wiki that new posts to this blog -should default to being [[SubPage]]s of "blog", and enables a form at the -top of the blog that can be used to add new items. +The optional `rootpage` parameter tells the wiki that new posts to this +blog should default to being [[SubPages|SubPage]] of "blog", and enables a +form at the top of the blog that can be used to add new items. If you want your blog to have an archive page listing every post ever made to it, you can accomplish that like this: diff --git a/ikiwiki/directive.mdwn b/ikiwiki/directive.mdwn new file mode 100644 index 0000000..a0a4e1f --- /dev/null +++ b/ikiwiki/directive.mdwn @@ -0,0 +1,39 @@ +[[!meta robots="noindex, follow"]] +Directives are similar to a [[WikiLink]] in form, except they +begin with `!` and may contain parameters. The general form is: + + \[[!directive param="value" param="value"]] + +This gets expanded before the rest of the page is processed, and can be used +to transform the page in various ways. + +The quotes around values can be omitted if the value is a simple word. +Also, some directives may use parameters without values, for example: + + \[[!tag foo]] + +A directive does not need to all be on one line, it can be +wrapped to multiple lines if you like: + + \[[!directive foo="baldersnatch" + bar="supercalifragilisticexpialidocious" baz=11]] + +Also, multiple lines of *quoted* text can be used for a value. +To allow quote marks inside the quoted text, delimit the block +of text with triple-quotes: + + \[[!directive text=""" + 1. "foo" + 2. "bar" + 3. "baz" + """]] + +ikiwiki also has an older syntax for directives, which requires a +space in directives to distinguish them from [[wikilinks|wikilink]]. This +syntax has several disadvantages: it requires a space after directives with no +parameters (such as `\[[pagecount ]]`), and it prohibits spaces in +[[wikilinks|wikilink]]. ikiwiki now provides the `!`-prefixed syntax shown +above as the preferred alternative. However, ikiwiki still supports wikis +using the older syntax, if the `prefix_directives` option is not enabled. +For backward compatibility with existing wikis, this option currently +defaults to off, so ikiwiki supports the old syntax. diff --git a/ikiwiki/formatting.mdwn b/ikiwiki/formatting.mdwn index 29dbce1..0145f9d 100644 --- a/ikiwiki/formatting.mdwn +++ b/ikiwiki/formatting.mdwn @@ -70,26 +70,37 @@ you use the following additional features: \[[!wikipedia War\_of\_1812]] """]] +[[!if test="enabled(template) and templates" then=""" +* Create and fill out [[templates]] for repeated chunks of + parameterized wiki text. +"""]] + +* Insert various [[directives|directive]] onto a page to perform useful + actions. +[[!if test="enabled(toc) or enabled(meta) or (enabled(inline) and blog)" then=""" + For example, you can: +"""]] + [[!if test="enabled(toc)" then=""" -* Add a table of contents to a page: + * Add a table of contents to a page: - \[[!toc ]] + \[[!toc]] """]] [[!if test="enabled(meta)" then=""" -* Change the title of a page: + * Change the title of a page: \[[!meta title="full page title"]] """]] [[!if test="enabled(inline) and blog" then=""" -* Create a [[blog]] by inlining a set of pages: + * Create a [[blog]] by inlining a set of pages: \[[!inline pages="blog/*"]] """]] -[[!if test="enabled(template) and templates" then=""" -* Create and fill out [[templates]] for repeated chunks of - parameterized wiki text. +[[!if test="enabled(listdirectives)" then=""" + Full list of [[directives|directive]] enabled for this wiki: + [[!listdirectives ]] """]] diff --git a/ikiwiki/markdown.mdwn b/ikiwiki/markdown.mdwn index bbda9ad..a419094 100644 --- a/ikiwiki/markdown.mdwn +++ b/ikiwiki/markdown.mdwn @@ -8,6 +8,6 @@ For documentation about the markdown syntax, see [[formatting]] and [markdown mode](http://jblevins.org/projects/markdown-mode/) for emacs can help in editing. -Note that [[WikiLink]]s and [[PreProcessorDirective]]s are not part of the -markdown syntax, and are the only bit of markup that this wiki handles -internally. +Note that [[WikiLinks|WikiLink]] and [[directives|directive]] are not part +of the markdown syntax, and are the only bit of markup that this wiki +handles internally. diff --git a/ikiwiki/pagespec/attachment.mdwn b/ikiwiki/pagespec/attachment.mdwn index 2a1f8aa..6b86c51 100644 --- a/ikiwiki/pagespec/attachment.mdwn +++ b/ikiwiki/pagespec/attachment.mdwn @@ -4,8 +4,8 @@ else="This wiki has attachments **disabled**."]] If attachments are enabled, the wiki admin can control what types of -attachments will be accepted, by entering a [[ikiwiki/PageSpec]] in the -"Allowed Attachments" field of their preferences page. +attachments will be accepted, via the `allowed_attachments` +configuration setting. For example, to limit arbitrary files to 50 kilobytes, but allow larger mp3 files to be uploaded by joey into a specific directory, and @@ -13,7 +13,7 @@ check all attachments for virii, something like this could be used: virusfree() and ((user(joey) and podcast/*.mp3 and mimetype(audio/mpeg) and maxsize(15mb)) or (!ispage() and maxsize(50kb))) -The regular [[ikiwiki/PageSpec]] syntax is expanded with thw following +The regular [[ikiwiki/PageSpec]] syntax is expanded with the following additional tests: * maxsize(size) diff --git a/ikiwiki/preprocessordirective.mdwn b/ikiwiki/preprocessordirective.mdwn index 743c0d9..bd12895 100644 --- a/ikiwiki/preprocessordirective.mdwn +++ b/ikiwiki/preprocessordirective.mdwn @@ -1,39 +1,7 @@ +[[!meta redir=ikiwiki/directive delay=10]] [[!meta robots="noindex, follow"]] -Preprocessor directives are similar to a [[WikiLink]] in form, except they -begin with `!` and may contain parameters. The general form is: - \[[!directive param="value" param="value"]] - -This gets expanded before the rest of the page is processed, and can be used -to transform the page in various ways. - -The quotes around values can be omitted if the value is a simple word. -Also, some directives may use parameters without values, for example: - - \[[!tag foo]] - -A preprocessor directive does not need to all be on one line, it can be -wrapped to multiple lines if you like: - - \[[!directive foo="baldersnatch" - bar="supercalifragalisticexpealadocious" baz=11]] - -Also, multiple lines of *quoted* text can be used for a value. -To allow quote marks inside the quoted text, delimit the block -of text with triple-quotes: - - \[[!directive text=""" - 1. "foo" - 2. "bar" - 3. "baz" - """]] - -ikiwiki also has an older syntax for preprocessor directives, which requires a -space in directives to distinguish them from [[wikilinks|wikilink]]. This -syntax has several disadvantages: it requires a space after directives with no -parameters (such as `\[[pagecount ]]`), and it prohibits spaces in -[[wikilinks|wikilink]]. ikiwiki now provides the `!`-prefixed syntax shown -above as the preferred alternative. However, ikiwiki still supports wikis -using the older syntax, if the `prefix_directives` option is not enabled. -For backward compatibility with existing wikis, this option currently -defaults to off, so ikiwiki supports the old syntax. +This page has moved to +[[ikiwiki/directive|ikiwiki/directive]]. Please +update your links, as this redirection page will be removed in a future +ikiwiki release. diff --git a/ikiwiki/wikilink.mdwn b/ikiwiki/wikilink.mdwn index bd5e3d1..371c252 100644 --- a/ikiwiki/wikilink.mdwn +++ b/ikiwiki/wikilink.mdwn @@ -23,11 +23,11 @@ page, but the link will appear like this: [[foo_bar|SandBox]]. To link to an anchor inside a page, you can use something like `\[[WikiLink#foo]]` -## Preprocessor directives and wikilinks +## Directives and WikiLinks ikiwiki has two syntaxes for -[[preprocessor_directives|PreprocessorDirective]]. The older syntax -used spaces to distinguish between preprocessor directives and +[[directives|directive]]. The older syntax +used spaces to distinguish between directives and wikilinks; as a result, with that syntax in use, you cannot use spaces in WikiLinks, and must replace spaces with underscores. The newer syntax, enabled with the `prefix_directives` option in an ikiwiki diff --git a/preprocessordirective.mdwn b/preprocessordirective.mdwn index 842ebfb..bd12895 100644 --- a/preprocessordirective.mdwn +++ b/preprocessordirective.mdwn @@ -1,7 +1,7 @@ -[[!meta redir=ikiwiki/preprocessordirective delay=10]] +[[!meta redir=ikiwiki/directive delay=10]] [[!meta robots="noindex, follow"]] This page has moved to -[[ikiwiki/preprocessordirective|ikiwiki/preprocessordirective]]. Please +[[ikiwiki/directive|ikiwiki/directive]]. Please update your links, as this redirection page will be removed in a future ikiwiki release. diff --git a/shortcuts.mdwn b/shortcuts.mdwn index 037c31e..4bb6774 100644 --- a/shortcuts.mdwn +++ b/shortcuts.mdwn @@ -61,13 +61,13 @@ This page controls what shortcut links the wiki supports. * [[!shortcut name=ohloh url="http://www.ohloh.net/projects/%s"]] To add a new shortcut, use the `shortcut` -[[ikiwiki/PreprocessorDirective]]. In the url, "%s" is replaced with the +[[ikiwiki/directive]]. In the url, "%s" is replaced with the text passed to the named shortcut, after url-encoding it, and '%S' is replaced with the raw, non-encoded text. The optional `desc` parameter controls the description of the link. Remember that the `name` you give the shortcut will become a new -[[ikiwiki/PreprocessorDirective]]. Avoid using a `name` that conflicts +[[ikiwiki/directive]]. Avoid using a `name` that conflicts with an existing directive. These directives also accept a `desc` parameter that will override the one provided at definition time. @@ -82,6 +82,7 @@ div.recentchanges { border-style: solid; border-width: 1px; overflow: auto; + clear: both; width: 100%; background: #eee; color: black !important; @@ -205,6 +206,8 @@ div.recentchanges { margin-left: 40px; margin-bottom: 40px; padding: 2ex 2ex; + background: white; + color: black !important; } /* outlines */ @@ -254,6 +257,14 @@ input#openid_url { padding-left: 18px; } +input#searchbox { + background: url(wikiicons/search-bg.gif) no-repeat; + background-color: #fff; + background-position: 100% 50%; + color: #000; + padding-right: 16px; +} + /* Things to hide in printouts. */ @media print { .actions { display: none; } @@ -272,6 +283,8 @@ input#openid_url { margin-bottom: 1ex; padding: 1ex 1ex; border: 1px solid #aaa; + background: white; + color: black !important; } /* Provided for use by template plugin for floating note boxes. */ @@ -283,6 +296,8 @@ input#openid_url { padding: 1ex 1ex; border: 1px solid #aaa; width: 25% + background: white; + color: black !important; } /* Used by the popup template and for backlinks hiding. */ @@ -333,3 +348,7 @@ legend { background: #eee; color: black !important; } + +span.color { + padding: 2px; +} diff --git a/templates.mdwn b/templates.mdwn index b40e865..1c234e3 100644 --- a/templates.mdwn +++ b/templates.mdwn @@ -65,7 +65,7 @@ few things: Here's a sample template: <span class="infobox"> - Name: [[<TMPL_VAR raw_name>]]<br /> + Name: \[[<TMPL_VAR raw_name>]]<br /> Age: <TMPL_VAR age><br /> <TMPL_IF NAME="color"> Favorite color: <TMPL_VAR color><br /> diff --git a/wikiicons/search-bg.gif b/wikiicons/search-bg.gif Binary files differnew file mode 100644 index 0000000..02f9da4 --- /dev/null +++ b/wikiicons/search-bg.gif |