summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonas Smedegaard <dr@jones.dk>2010-07-17 15:21:24 +0200
committerJonas Smedegaard <dr@jones.dk>2010-07-17 15:21:24 +0200
commit8a6868efccbba0c8f6fbb35e2f19c79d794221e5 (patch)
treebe35890e81c2ab9a5f333607f957204099d10fbf
parent262712e706420c9f421c7a4fc7a33ebe9bf1b1bf (diff)
parent6b53960c5bbcf6a43f2e48b0b37a94e1f909b522 (diff)
Merge branch 'master' into scsscs
-rw-r--r--directive.mdwn45
-rw-r--r--ikiwiki.mdwn1
-rw-r--r--ikiwiki/blog.mdwn8
-rw-r--r--ikiwiki/directive.mdwn16
-rw-r--r--ikiwiki/formatting.mdwn2
-rw-r--r--ikiwiki/markdown.mdwn4
-rw-r--r--ikiwiki/openid.mdwn12
-rw-r--r--ikiwiki/pagespec.mdwn49
-rw-r--r--ikiwiki/pagespec/attachment.mdwn19
-rw-r--r--ikiwiki/pagespec/po.mdwn20
-rw-r--r--ikiwiki/pagespec/sorting.mdwn26
-rw-r--r--ikiwiki/preprocessordirective.mdwn7
-rw-r--r--ikiwiki/searching.mdwn2
-rw-r--r--ikiwiki/subpage.mdwn4
-rw-r--r--ikiwiki/wikilink.mdwn25
-rw-r--r--index.mdwn2
-rw-r--r--shortcuts.mdwn12
-rw-r--r--style.css359
-rw-r--r--templates.mdwn147
-rw-r--r--templates/note.mdwn2
-rw-r--r--templates/popup.mdwn2
-rw-r--r--wikiicons/openidlogin-bg.gifbin142 -> 336 bytes
22 files changed, 414 insertions, 350 deletions
diff --git a/directive.mdwn b/directive.mdwn
deleted file mode 100644
index c4342de..0000000
--- a/directive.mdwn
+++ /dev/null
@@ -1,45 +0,0 @@
-[[!meta robots="noindex, follow"]]
-Directives are similar to a [[ikiwiki/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|ikiwiki/wikilink]].
-This syntax has several disadvantages: it requires a space after directives
-with no parameters (such as `\[[pagecount ]]`), and it prohibits spaces in
-[[wikilinks|ikiwiki/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.
-
-[[!if test="enabled(listdirectives)" then="""
-Here is a list of currently available directives in this wiki:
-
-[[!listdirectives ]]
-"""]]
diff --git a/ikiwiki.mdwn b/ikiwiki.mdwn
index e0a971d..4d84069 100644
--- a/ikiwiki.mdwn
+++ b/ikiwiki.mdwn
@@ -14,3 +14,4 @@ Some documentation on using ikiwiki:
* [[ikiwiki/markdown]]
* [[ikiwiki/openid]]
* [[ikiwiki/searching]]
+* [[templates]]
diff --git a/ikiwiki/blog.mdwn b/ikiwiki/blog.mdwn
deleted file mode 100644
index 0a5a524..0000000
--- a/ikiwiki/blog.mdwn
+++ /dev/null
@@ -1,8 +0,0 @@
-[[!meta robots="noindex, follow"]]
-
-This page has been removed from ikiwiki's basewiki. For documentation about
-creating a blog with ikiwiki, see the documentation of the
-[[!iki ikiwiki/directive/inline desc=inline]] directive.
-
-Please update your links, as this redirection page will be removed in a
-future ikiwiki release.
diff --git a/ikiwiki/directive.mdwn b/ikiwiki/directive.mdwn
index c4342de..fb88aa7 100644
--- a/ikiwiki/directive.mdwn
+++ b/ikiwiki/directive.mdwn
@@ -28,15 +28,13 @@ of text with triple-quotes:
3. "baz"
"""]]
-ikiwiki also has an older syntax for directives, which requires a
-space in directives to distinguish them from [[wikilinks|ikiwiki/wikilink]].
-This syntax has several disadvantages: it requires a space after directives
-with no parameters (such as `\[[pagecount ]]`), and it prohibits spaces in
-[[wikilinks|ikiwiki/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.
+ikiwiki also has an older syntax for directives, which requires a space in
+directives to distinguish them from [[wikilinks|ikiwiki/wikilink]]. This
+syntax has several disadvantages: it requires a space after directives with
+no parameters (such as `\[[pagecount ]]`), and it prohibits spaces in
+[[wikilinks|ikiwiki/wikilink]]. ikiwiki now provides the `!`-prefixed
+syntax shown above as default. However, ikiwiki still supports wikis using
+the older syntax, if the `prefix_directives` option is disabled.
[[!if test="enabled(listdirectives)" then="""
Here is a list of currently available directives in this wiki:
diff --git a/ikiwiki/formatting.mdwn b/ikiwiki/formatting.mdwn
index 2ed5cc2..befbce9 100644
--- a/ikiwiki/formatting.mdwn
+++ b/ikiwiki/formatting.mdwn
@@ -7,7 +7,7 @@ called [[MarkDown]], and it works like this:
Leave blank lines between paragraphs.
-You can \**emphasise*\* or \*\***strongly emphasise**\*\* text by placing it
+You can *\*emphasise\** or **\*\*strongly emphasise\*\*** text by placing it
in single or double asterisks.
To create a list, start each line with an asterisk:
diff --git a/ikiwiki/markdown.mdwn b/ikiwiki/markdown.mdwn
index a419094..6841919 100644
--- a/ikiwiki/markdown.mdwn
+++ b/ikiwiki/markdown.mdwn
@@ -4,9 +4,7 @@ is a minimal markup language that resembles plain text as used in
email messages. It is the markup language used by this wiki by default.
For documentation about the markdown syntax, see [[formatting]] and
-[Markdown: syntax](http://daringfireball.net/projects/markdown/syntax). A
-[markdown mode](http://jblevins.org/projects/markdown-mode/) for
-emacs can help in editing.
+[Markdown: syntax](http://daringfireball.net/projects/markdown/syntax).
Note that [[WikiLinks|WikiLink]] and [[directives|directive]] are not part
of the markdown syntax, and are the only bit of markup that this wiki
diff --git a/ikiwiki/openid.mdwn b/ikiwiki/openid.mdwn
index dd851e5..2fa972e 100644
--- a/ikiwiki/openid.mdwn
+++ b/ikiwiki/openid.mdwn
@@ -9,16 +9,10 @@
that allows you to have one login that you can use on a growing number of
websites.
-To sign up for an OpenID, visit one of the following identity providers:
+If you have an account with some of the larger web service providers,
+you might already have an OpenID.
+[Directory of OpenID providers](http://openiddirectory.com/openid-providers-c-1.html)
-* [MyOpenID](https://www.myopenid.com/)
-* [GetOpenID](https://getopenid.com/)
-* [Videntity](http://videntity.org/)
-* [LiveJournal](http://www.livejournal.com/openid/)
-* [TrustBearer](https://openid.trustbearer.com/)
-* or any of the [many others out there](http://openiddirectory.com/openid-providers-c-1.html).
-
-Your OpenID is the URL that you are given when you sign up.
[[!if test="enabled(openid)" then="""
To sign in to this wiki using OpenID, just enter it in the OpenID field in the
signin form. You do not need to give this wiki a password or go through any
diff --git a/ikiwiki/pagespec.mdwn b/ikiwiki/pagespec.mdwn
index c78666c..c66395f 100644
--- a/ikiwiki/pagespec.mdwn
+++ b/ikiwiki/pagespec.mdwn
@@ -24,29 +24,37 @@ match all pages except for Discussion pages and the SandBox:
Some more elaborate limits can be added to what matches using these functions:
-* "`link(page)`" - match only pages that link to a given page (or glob)
-* "`backlink(page)`" - match only pages that a given page links to
-* "`creation_month(month)`" - match only pages created on the given month
+* "`glob(someglob)`" - matches pages and other files that match the given glob.
+ Just writing the glob by itself is actually a shorthand for this function.
+* "`page(glob)`" - like `glob()`, but only matches pages, not other files
+* "`link(page)`" - matches only pages that link to a given page (or glob)
+* "`tagged(tag)`" - matches pages that are tagged or link to the given tag (or
+ tags matched by a glob)
+* "`backlink(page)`" - matches only pages that a given page links to
+* "`creation_month(month)`" - matches only files created on the given month
* "`creation_day(mday)`" - or day of the month
* "`creation_year(year)`" - or year
-* "`created_after(page)`" - match only pages created after the given page
+* "`created_after(page)`" - matches only files created after the given page
was created
-* "`created_before(page)`" - match only pages created before the given page
+* "`created_before(page)`" - matches only files created before the given page
was created
-* "`glob(someglob)`" - match pages that match the given glob. Just writing
- the glob by itself is actually a shorthand for this function.
* "`internal(glob)`" - like `glob()`, but matches even internal-use
pages that globs do not usually match.
* "`title(glob)`", "`author(glob)`", "`authorurl(glob)`",
- "`license(glob)`", "`copyright(glob)`" - match pages that have the given
- metadata, matching the specified glob.
+ "`license(glob)`", "`copyright(glob)`", "`guid(glob)`"
+ - match pages that have the given metadata, matching the specified glob.
* "`user(username)`" - tests whether a modification is being made by a
user with the specified username. If openid is enabled, an openid can also
- be put here.
+ be put here. Glob patterns can be used in the username. For example,
+ to match all openid users, use `user(*://*)`
* "`admin()`" - tests whether a modification is being made by one of the
wiki admins.
* "`ip(address)`" - tests whether a modification is being made from the
specified IP address.
+* "`comment(glob)`" - matches comments to a page matching the glob.
+* "`comment_pending(glob)`" - matches unmoderated, pending comments.
+* "`postcomment(glob)`" - matches only when comments are being
+ posted to a page matching the specified glob
For example, to match all pages in a blog that link to the page about music
and were written in 2005:
@@ -63,29 +71,10 @@ More complex expressions can also be created, by using parentheses for
grouping. For example, to match pages in a blog that are tagged with either
of two tags, use:
- blog/* and (link(tag/foo) or link(tag/bar))
+ blog/* and (tagged(foo) or tagged(bar))
Note that page names in PageSpecs are matched against the absolute
filenames of the pages in the wiki, so a pagespec "foo" used on page
"a/b" will not match a page named "a/foo" or "a/b/foo". To match
relative to the directory of the page containing the pagespec, you can
use "./". For example, "./foo" on page "a/b" matches page "a/foo".
-
-## Old syntax
-
-The old PageSpec syntax was called a "GlobList", and worked differently in
-two ways:
-
-1. "and" and "or" were not used; any page matching any item from the list
- matched.
-2. If an item was prefixed with "`!`", then no page matching that item
- matched, even if it matched an earlier list item.
-
-For example, here is the old way to match all pages except for the SandBox
-and Discussion pages:
-
- * !SandBox !*/Discussion
-
-Using this old syntax is still supported. However, the old syntax is
-deprecated and will be removed at some point, and using the new syntax is
-recommended.
diff --git a/ikiwiki/pagespec/attachment.mdwn b/ikiwiki/pagespec/attachment.mdwn
index 2d33db7..fa2bc58 100644
--- a/ikiwiki/pagespec/attachment.mdwn
+++ b/ikiwiki/pagespec/attachment.mdwn
@@ -7,23 +7,24 @@ If attachments are enabled, the wiki admin can control what types of
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
-check all attachments for virii, something like this could be used:
+For example, to limit most users to uploading small images, and nothing else,
+while allowing larger mp3 files to be uploaded by joey into a specific
+directory, and check all attachments for viruses, 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)))
+ virusfree() and ((user(joey) and podcast/*.mp3 and mimetype(audio/mpeg) and maxsize(15mb)) or (mimetype(image/*) and maxsize(50kb)))
The regular [[ikiwiki/PageSpec]] syntax is expanded with the following
additional tests:
-* "`maxsize(size)`" - Tests whether the attachment is no larger than the
+* "`maxsize(size)`" - tests whether the attachment is no larger than the
specified size. The size defaults to being in bytes, but "kb", "mb", "gb"
etc can be used to specify the units.
-* "`minsize(size)`" - Tests whether the attachment is no smaller than the
+* "`minsize(size)`" - tests whether the attachment is no smaller than the
specified size.
-* "`ispage()`" - Tests whether the attachment will be treated by ikiwiki as a
+* "`ispage()`" - tests whether the attachment will be treated by ikiwiki as a
wiki page. (Ie, if it has an extension of ".mdwn", or of any other enabled
page format).
@@ -31,7 +32,7 @@ additional tests:
use `!ispage()` ; if you only want to allow wiki pages to be uploaded
as attachments, use `ispage()`.
-* "`mimetype(foo/bar)`" - This checks the MIME type of the attachment. You can
+* "`mimetype(foo/bar)`" - checks the MIME type of the attachment. You can
include a glob in the type, for example `mimetype(image/*)`.
-* "`virusfree()`" - Checks the attachment with an antiviral program.
+* "`virusfree()`" - checks the attachment with an antiviral program.
diff --git a/ikiwiki/pagespec/po.mdwn b/ikiwiki/pagespec/po.mdwn
new file mode 100644
index 0000000..f8b3985
--- /dev/null
+++ b/ikiwiki/pagespec/po.mdwn
@@ -0,0 +1,20 @@
+[[!if test="enabled(po)"
+ then="This wiki has po support **enabled**."
+ else="This wiki has po support **disabled**."]]
+
+If the [[!iki plugins/po desc=po]] plugin is enabled, the regular
+[[ikiwiki/PageSpec]] syntax is expanded with the following additional
+tests that can be used to improve user navigation in a multi-lingual
+wiki:
+
+* "`lang(LL)`" - tests whether a page is written in the language
+ specified as a ISO639-1 (two-letter) language code.
+* "`currentlang()`" - tests whether a page is written in the same
+ language as the current page.
+* "`needstranslation()`" - tests whether a page needs translation
+ work. Only slave pages match this PageSpec.
+
+Note that every non-po page is considered to be written in
+`po_master_language`, as specified in `ikiwiki.setup`.
+
+[[!meta robots="noindex, follow"]]
diff --git a/ikiwiki/pagespec/sorting.mdwn b/ikiwiki/pagespec/sorting.mdwn
new file mode 100644
index 0000000..ccd7f7e
--- /dev/null
+++ b/ikiwiki/pagespec/sorting.mdwn
@@ -0,0 +1,26 @@
+Some [[directives|ikiwiki/directive]] that use
+[[PageSpecs|ikiwiki/pagespec]] allow
+specifying the order that matching pages are shown in. The following sort
+orders can be specified.
+
+* `age` - List pages from the most recently created to the oldest.
+
+* `mtime` - List pages with the most recently modified first.
+
+* `title` - Order by title (page name).
+[[!if test="enabled(sortnaturally)" then="""
+* `title_natural` - Orders by title, but numbers in the title are treated
+ as such, ("1 2 9 10 20" instead of "1 10 2 20 9")
+"""]]
+[[!if test="enabled(meta)" then="""
+* `meta(title)` - Order according to the `\[[!meta title="foo" sortas="bar"]]`
+ or `\[[!meta title="foo"]]` [[ikiwiki/directive]], or the page name if no
+ full title was set. `meta(author)`, `meta(date)`, `meta(updated)`, etc.
+ also work.
+"""]]
+
+In addition, you can combine several sort orders and/or reverse the order of
+sorting, with a string like `age -title` (which would sort by age, then by
+title in reverse order if two pages have the same age).
+
+[[!meta robots="noindex, follow"]]
diff --git a/ikiwiki/preprocessordirective.mdwn b/ikiwiki/preprocessordirective.mdwn
deleted file mode 100644
index bd12895..0000000
--- a/ikiwiki/preprocessordirective.mdwn
+++ /dev/null
@@ -1,7 +0,0 @@
-[[!meta redir=ikiwiki/directive delay=10]]
-[[!meta robots="noindex, follow"]]
-
-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/searching.mdwn b/ikiwiki/searching.mdwn
index 539e719..4c12879 100644
--- a/ikiwiki/searching.mdwn
+++ b/ikiwiki/searching.mdwn
@@ -5,7 +5,7 @@ then="This wiki has searching **enabled**."
else="This wiki has searching **disabled**."]]
If searching is enabled, you can enter search terms in the search field,
-as you'd expect. There are a few special things you can do to constuct
+as you'd expect. There are a few special things you can do to construct
more powerful searches.
* To match a phrase, enclose it in double quotes.
diff --git a/ikiwiki/subpage.mdwn b/ikiwiki/subpage.mdwn
index e047b86..862f45e 100644
--- a/ikiwiki/subpage.mdwn
+++ b/ikiwiki/subpage.mdwn
@@ -5,8 +5,8 @@ this page, [[SubPage]] has some related pages placed under it, like
wiki rather than just having a great big directory full of pages.
To add a SubPage, just make a subdirectory and put pages in it. For
-example, this page is SubPage.mdwn in this wiki's source, and there is also
-a SubPage subdirectory, which contains SubPage/LinkingRules.mdwn. Subpages
+example, this page is subpage.mdwn in this wiki's source, and there is also
+a subpage subdirectory, which contains subpage/linkingrules.mdwn. Subpages
can be nested as deeply as you'd like.
Linking to and from a SubPage is explained in [[LinkingRules]].
diff --git a/ikiwiki/wikilink.mdwn b/ikiwiki/wikilink.mdwn
index 371c252..cf3b89c 100644
--- a/ikiwiki/wikilink.mdwn
+++ b/ikiwiki/wikilink.mdwn
@@ -9,9 +9,6 @@ wikilink, just prefix it with a `\`, like `\\[[WikiLink]]`.
There are some special [[SubPage/LinkingRules]] that come into play when
linking between [[SubPages|SubPage]].
-Also, if the file linked to by a WikiLink looks like an image, it will
-be displayed inline on the page.
-
WikiLinks are matched with page names in a case-insensitive manner, so you
don't need to worry about getting the case the same, and can capitalise
links at the start of a sentence, and so on.
@@ -21,16 +18,12 @@ name as the link text. For example `\[[foo_bar|SandBox]]` links to the SandBox
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]]`
-
-## Directives and WikiLinks
-
-ikiwiki has two syntaxes for
-[[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
-setup file, prefixes directives with `!`, and thus does not prevent
-links with spaces. Future versions of ikiwiki will turn this option
-on by default.
+`\[[WikiLink#foo]]` .
+
+If the file linked to by a WikiLink looks like an image, it will
+be displayed inline on the page.
+
+---
+
+You can also put an url in a WikiLink, to link to an external page.
+Email addresses can also be used to generate a mailto link.
diff --git a/index.mdwn b/index.mdwn
index 05834e0..4187c11 100644
--- a/index.mdwn
+++ b/index.mdwn
@@ -4,4 +4,4 @@ All wikis are supposed to have a [[SandBox]], so this one does too.
----
-This wiki is powered by [ikiwiki](http://ikiwiki.info/).
+This wiki is powered by [[ikiwiki]].
diff --git a/shortcuts.mdwn b/shortcuts.mdwn
index 14cd5ff..54dd0fd 100644
--- a/shortcuts.mdwn
+++ b/shortcuts.mdwn
@@ -18,7 +18,7 @@ This page controls what shortcut links the wiki supports.
* [[!shortcut name=wikipedia url="http://en.wikipedia.org/wiki/%s"]]
* [[!shortcut name=wikitravel url="http://wikitravel.org/en/%s"]]
* [[!shortcut name=wiktionary url="http://en.wiktionary.org/wiki/%s"]]
-* [[!shortcut name=debbug url="http://bugs.debian.org/%s" desc="bug #%s"]]
+* [[!shortcut name=debbug url="http://bugs.debian.org/%S" desc="Debian bug #%s"]]
* [[!shortcut name=deblist url="http://lists.debian.org/debian-%s" desc="debian-%s@lists.debian.org"]]
* [[!shortcut name=debpkg url="http://packages.debian.org/%s"]]
* [[!shortcut name=debpkgsid url="http://packages.debian.org/sid/%s"]]
@@ -59,12 +59,14 @@ This page controls what shortcut links the wiki supports.
* [[!shortcut name=flickr url="http://www.flickr.com/photos/%s"]]
* [[!shortcut name=man url="http://linux.die.net/man/%s"]]
* [[!shortcut name=ohloh url="http://www.ohloh.net/projects/%s"]]
+* [[!shortcut name=cpanrt url="https://rt.cpan.org/Ticket/Display.html?id=%s" desc="CPAN RT#%s"]]
+* [[!shortcut name=novellbug url="https://bugzilla.novell.com/show_bug.cgi?id=%s" desc="bug %s"]]
To add a new shortcut, use the `shortcut`
[[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.
+text passed to the named shortcut, after [[!wikipedia 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/directive]]. Avoid using a `name` that conflicts
@@ -73,5 +75,5 @@ parameter that will override the one provided at definition time.
If you come up with a shortcut that you think others might find useful,
consider contributing it to the [shortcuts page on the ikiwiki
-ikiwiki](http://ikiwiki.info/shortcuts/), so that future versions of
+wiki](http://ikiwiki.info/shortcuts/), so that future versions of
ikiwiki will include your shortcut in the standard underlay.
diff --git a/style.css b/style.css
index 5787ef6..bf000da 100644
--- a/style.css
+++ b/style.css
@@ -4,6 +4,14 @@
* local.css and use it to override or change settings in this one.
*/
+/* html5 compat */
+article,
+header,
+footer,
+nav {
+ display: block;
+}
+
.header {
margin: 0;
font-size: 22px;
@@ -12,7 +20,7 @@
display: block;
}
-.author {
+.inlineheader .author {
margin: 0;
font-size: 18px;
font-weight: bold;
@@ -21,8 +29,15 @@
.actions ul {
margin: 0;
- padding: 6px;
+ padding: 6px .4em;
+ height: 1em;
list-style-type: none;
+}
+.actions li {
+ display: inline;
+ padding: .2em;
+}
+.pageheader .actions ul {
border-bottom: 1px solid #000;
}
@@ -30,20 +45,27 @@
border-bottom: 0;
}
-div.inlinecontent {
- margin-top: .4em;
+#otherlanguages ul {
+ margin: 0;
+ padding: 6px;
+ list-style-type: none;
}
-
-.actions li {
+#otherlanguages li {
display: inline;
padding: .2em .4em;
}
+.pageheader #otherlanguages {
+ border-bottom: 1px solid #000;
+}
-.pagefooter {
- clear: both;
+.inlinecontent {
+ margin-top: .4em;
}
-.tags {
+.pagefooter,
+.inlinefooter,
+.comments {
+ clear: both;
}
#pageinfo {
@@ -51,10 +73,14 @@ div.inlinecontent {
border-top: 1px solid #000;
}
-div.tags {
+.tags {
margin-top: 1em;
}
+.inlinepage .tags {
+ display: inline;
+}
+
.mapparent {
text-decoration: none;
}
@@ -65,6 +91,14 @@ div.tags {
text-align: center;
}
+.align-left {
+ float:left;
+}
+
+.align-right {
+ float:right;
+}
+
#backlinks {
margin-top: 1em;
}
@@ -75,19 +109,28 @@ div.tags {
}
#editcontent {
- width: 100%;
+ width: 98%;
+}
+
+.editcontentdiv {
+ width: auto;
+ overflow: auto;
}
img {
border-style: none;
}
+pre {
+ overflow: auto;
+}
+
div.recentchanges {
border-style: solid;
border-width: 1px;
overflow: auto;
- clear: both;
- width: 100%;
+ width: auto;
+ clear: none;
background: #eee;
color: black !important;
}
@@ -131,17 +174,19 @@ div.recentchanges {
width: 60%;
}
-/* Used for adding a blog page. */
#blogform {
padding: 10px 10px;
border: 1px solid #aaa;
background: #eee;
color: black !important;
+ width: auto;
+ overflow: auto;
}
.inlinepage {
padding: 10px 10px;
border: 1px solid #aaa;
+ overflow: auto;
}
.pagedate,
@@ -156,90 +201,18 @@ div.recentchanges {
color: #C00;
}
-/* Used for invalid form fields. */
-.fb_invalid {
- color: red;
- background: white !important;
-}
-
-/* Used for required form fields. */
-.fb_required {
- font-weight: bold;
-}
-
-/* Orange feed button. */
-.feedbutton {
- background: #ff6600;
- color: white !important;
- border-left: 1px solid #cc9966;
- border-top: 1px solid #ccaa99;
- border-right: 1px solid #993300;
- border-bottom: 1px solid #331100;
- padding: 0px 0.5em 0px 0.5em;
- font-family: sans-serif;
- font-weight: bold;
- font-size: small;
- text-decoration: none;
- margin-top: 1em;
-}
-.feedbutton:hover {
- color: white !important;
- background: #ff9900;
-}
-
-/* Tag cloud. */
-.pagecloud {
- float: right;
- width: 30%;
- text-align: center;
- padding: 10px 10px;
- border: 1px solid #aaa;
- background: #eee;
- color: black !important;
-}
-.smallestPC { font-size: 70%; }
-.smallPC { font-size: 85%; }
-.normalPC { font-size: 100%; }
-.bigPC { font-size: 115%; }
-.biggestPC { font-size: 130%; }
-
-#sidebar {
- line-height: 3ex;
+.sidebar {
width: 20ex;
float: right;
- margin-left: 40px;
- margin-bottom: 40px;
- padding: 2ex 2ex;
+ margin-left: 4px;
+ margin-bottom: 4px;
+ margin-top: -1px;
+ padding: 0ex 2ex;
background: white;
+ border: 1px solid black;
color: black !important;
}
-/* outlines */
-li.L1 {
- list-style: upper-roman;
-}
-li.L2 {
- list-style: decimal;
-}
-li.L3 {
- list-style: lower-alpha;
-}
-li.L4 {
- list-style: disc;
-}
-li.L5 {
- list-style: square;
-}
-li.L6 {
- list-style: circle;
-}
-li.L7 {
- list-style: lower-roman;
-}
-li.L8 {
- list-style: upper-alpha;
-}
-
hr.poll {
height: 10pt;
color: white !important;
@@ -253,6 +226,27 @@ div.poll {
border: 1px solid #aaa;
}
+span.color {
+ padding: 2px;
+}
+
+.comment-header,
+.microblog-header {
+ font-style: italic;
+ margin-top: .3em;
+}
+.comment .author,
+.microblog .author {
+ font-weight: bold;
+}
+.comment-subject {
+ font-weight: bold;
+}
+.comment {
+ border: 1px solid #aaa;
+ padding: 3px;
+}
+
div.progress {
margin-top: 1ex;
margin-bottom: 1ex;
@@ -269,23 +263,7 @@ div.progress-done {
padding: 1px;
}
-input#openid_url {
- background: url(wikiicons/openidlogin-bg.gif) no-repeat;
- background-color: #fff;
- background-position: 0 50%;
- color: #000;
- 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. */
+/* things to hide in printouts */
@media print {
.actions { display: none; }
.tags { display: none; }
@@ -295,7 +273,7 @@ input#searchbox {
#backlinks { display: none; }
}
-/* Provided for use by template plugin for floating info boxes. */
+/* infobox template */
.infobox {
float: right;
margin-left: 2ex;
@@ -307,7 +285,7 @@ input#searchbox {
color: black !important;
}
-/* Provided for use by template plugin for floating note boxes. */
+/* notebox template */
.notebox {
float: right;
margin-left: 2ex;
@@ -320,7 +298,7 @@ input#searchbox {
color: black !important;
}
-/* Used by the popup template and for backlinks hiding. */
+/* popup template and backlinks hiding */
.popup {
border-bottom: 1px dotted #366;
color: #366;
@@ -339,14 +317,9 @@ input#searchbox {
border: 2px solid;
background-color: #dee;
color: black;
-
- /* Nonstandard, but very nice. */
- opacity: 0.95;
- -moz-opacity: 0.95;
- filter: alpha(opacity=95);
}
-/* Formbuilder styling */
+/* form styling */
fieldset {
margin: 1ex 0;
border: 1px solid black;
@@ -358,17 +331,153 @@ legend {
float: left;
margin: 2px 0;
}
-#signin_openid_url_label {
- float: left;
- margin-right: 1ex;
+label.block {
+ display: block;
+}
+label.inline {
+ display: inline;
+}
+input#openid_identifier {
+ background: url(wikiicons/openidlogin-bg.gif) no-repeat;
+ background-color: #fff;
+ background-position: 0 50%;
+ color: #000;
+ 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;
+}
+/* invalid form fields */
+.fb_invalid {
+ color: red;
+ background: white !important;
+}
+/* required form fields */
+.fb_required {
+ font-weight: bold;
+}
+
+/* highlight plugin */
+pre.hl { color:#000000; background-color:#ffffff; }
+.hl.num { color:#2928ff; }
+.hl.esc { color:#ff00ff; }
+.hl.str { color:#ff0000; }
+.hl.dstr { color:#818100; }
+.hl.slc { color:#838183; font-style:italic; }
+.hl.com { color:#838183; font-style:italic; }
+.hl.dir { color:#008200; }
+.hl.sym { color:#000000; }
+.hl.line { color:#555555; }
+.hl.mark { background-color:#ffffbb; }
+.hl.kwa { color:#000000; font-weight:bold; }
+.hl.kwb { color:#830000; }
+.hl.kwc { color:#000000; font-weight:bold; }
+.hl.kwd { color:#010181; }
+
+/* calendar plugin */
+.month-calendar-day-this-day,
+.year-calendar-this-month {
+ background-color: #eee;
+}
+.month-calendar-day-head,
+.month-calendar-day-nolink,
+.month-calendar-day-link,
+.month-calendar-day-this-day,
+.month-calendar-day-future {
+ text-align: right;
+}
+.month-calendar-arrow A:link,
+.year-calendar-arrow A:link,
+.month-calendar-arrow A:visited,
+.year-calendar-arrow A:visited {
+ text-decoration: none;
+ font-weight: normal;
+ font-size: 150%;
}
-#signin_openid {
+
+/* outlines */
+li.L1 { list-style: upper-roman; }
+li.L2 { list-style: decimal; }
+li.L3 { list-style: lower-alpha; }
+li.L4 { list-style: disc; }
+li.L5 { list-style: square; }
+li.L6 { list-style: circle; }
+li.L7 { list-style: lower-roman; }
+li.L8 { list-style: upper-alpha; }
+
+/* tag cloud */
+.pagecloud {
+ float: right;
+ width: 30%;
+ text-align: center;
padding: 10px 10px;
border: 1px solid #aaa;
- background: #eee;
+ background: #eee;
color: black !important;
}
+.smallestPC { font-size: 70%; }
+.smallPC { font-size: 85%; }
+.normalPC { font-size: 100%; }
+.bigPC { font-size: 115%; }
+.biggestPC { font-size: 130%; }
-span.color {
- padding: 2px;
+/* orange feed button */
+.feedbutton {
+ background: #ff6600;
+ color: white !important;
+ border-left: 1px solid #cc9966;
+ border-top: 1px solid #ccaa99;
+ border-right: 1px solid #993300;
+ border-bottom: 1px solid #331100;
+ padding: 0px 0.5em 0px 0.5em;
+ font-family: sans-serif;
+ font-weight: bold;
+ font-size: small;
+ text-decoration: none;
+ margin-top: 1em;
+}
+.feedbutton:hover {
+ color: white !important;
+ background: #ff9900;
+}
+
+/* openid selector */
+#openid_choice {
+ display: none;
+}
+#openid_input_area {
+ clear: both;
+ padding: 10px;
+}
+#openid_btns, #openid_btns br {
+ clear: both;
+}
+#openid_highlight {
+ background-color: black;
+ float: left;
+}
+.openid_large_btn {
+ padding: 1em 1.5em;
+ border: 1px solid #DDD;
+ margin: 3px;
+ float: left;
+}
+.openid_small_btn {
+ padding: 4px 4px;
+ border: 1px solid #DDD;
+ margin: 3px;
+ float: left;
+}
+a.openid_large_btn:focus {
+ outline: none;
+}
+a.openid_large_btn:focus {
+ -moz-outline-style: none;
+}
+.openid_selected {
+ border: 4px solid #DDD;
}
diff --git a/templates.mdwn b/templates.mdwn
index eff0e15..9eb12e8 100644
--- a/templates.mdwn
+++ b/templates.mdwn
@@ -1,87 +1,80 @@
-[[!meta robots="noindex, follow"]]
-[[!if test="enabled(template)"
-then="This wiki has templates **enabled**."
-else="This wiki has templates **disabled**."
-]]
-
-Templates are files that can be filled out and inserted into pages in the
-wiki.
-
-[[!if test="enabled(template) and enabled(inline)" then="""
-
-These templates are available for inclusion onto other pages in this
-wiki:
-
-[[!inline pages="templates/* and !*/discussion" feeds=no archive=yes
-sort=title template=titlepage]]
-"""]]
-
-## Using a template
-
-Using a template works like this:
-
- \[[!template id=note text="""Here is the text to insert into my note."""]]
+[[Ikiwiki]] uses many templates for many purposes. By editing its templates,
+you can fully customise this site.
-This fills out the [[note]] template, filling in the `text` field with
-the specified value, and inserts the result into the page.
+Templates are located in `/usr/share/ikiwiki/templates` by default;
+the `templatedir` setting can be used to make another directory be
+searched first. Customised templates can also be placed inside the
+"templates/" directory in your wiki's source.
-Generally, a value can include any markup that would be allowed in the wiki
-page outside the template. Triple-quoting the value even allows quotes to
-be included in it. Combined with multi-line quoted values, this allows for
-large chunks of marked up text to be embedded into a template:
+Ikiwiki uses the HTML::Template module as its template engine. This
+supports things like conditionals and loops in templates and is pretty
+easy to learn. All you really need to know to modify templates is this:
- \[[!template id=foo name="Sally" color="green" age=8 notes="""
- * \[[Charley]]'s sister.
- * "I want to be an astronaut when I grow up."
- * Really 8 and a half.
- """]]
+* To insert the value of a template variable, use `<TMPL_VAR variable>`.
+* To make a block of text conditional on a variable being set use
+ `<TMPL_IF variable>text</TMPL_IF>`.
+* To use one block of text if a variable is set and a second if it's not,
+ use `<TMPL_IF variable>text<TMPL_ELSE>other text</TMPL_IF>`
-## Creating a template
+[[!if test="enabled(template)" then="""
+## template pages
-To create a template, simply add a template directive to a page, and the
-page will provide a link that can be used to create the template. The template
-is a regular wiki page, located in the `templates/` subdirectory inside
-the source directory of the wiki.
+The [[!iki ikiwiki/directive/template desc="template directive"]] allows
+wiki pages to be used as templates, filled out and inserted into other
+pages in the wiki.
+"""]]
-The template uses the syntax used by the [[!cpan HTML::Template]] perl
-module, which allows for some fairly complex things to be done. Consult its
-documentation for the full syntax, but all you really need to know are a
-few things:
+[[!if test="enabled(edittemplate)" then="""
+## default content for new pages
-* Each parameter you pass to the template directive will generate a
- template variable. There are also some pre-defined variables like PAGE
- and BASENAME.
-* To insert the value of a variable, use `<TMPL_VAR variable>`. Wiki markup
- in the value will first be converted to html.
-* To insert the raw value of a variable, with wiki markup not yet converted
- to html, use `<TMPL_VAR raw_variable>`.
-* To make a block of text conditional on a variable being set use
- `<TMPL_IF NAME="variable">text</TMPL_IF>`.
-* To use one block of text if a variable is set and a second if it's not,
- use `<TMPL_IF NAME="variable">text<TMPL_ELSE>other text</TMPL_IF>`
-
-Here's a sample template:
+The [[!iki ikiwiki/directive/edittemplate desc="edittemplate directive"]] can
+be used to make new pages default to containing text from a template
+page, which can be filled as out the page is edited.
+"""]]
- <span class="infobox">
- Name: \[[<TMPL_VAR raw_name>]]<br />
- Age: <TMPL_VAR age><br />
- <TMPL_IF NAME="color">
- Favorite color: <TMPL_VAR color><br />
- <TMPL_ELSE>
- No favorite color.<br />
- </TMPL_IF>
- <TMPL_IF NAME="notes">
- <hr />
- <TMPL_VAR notes>
- </TMPL_IF>
- </span>
+[[!if test="(enabled(template) or enabled(edittemplate))
+and enabled(inline)" then="""
+[[!inline pages="templates/* and !*.tmpl and !templates/*/* and !*/discussion"
+feeds=no archive=yes sort=title template=titlepage
+rootpage=templates postformtext="Add a new template named:"]]
+"""]]
-The filled out template will be formatted the same as the rest of the page
-that contains it, so you can include WikiLinks and all other forms of wiki
-markup in the template. Note though that such WikiLinks will not show up as
-backlinks to the page that uses the template.
+## wiki templates
+
+These templates are used to build the wiki. The aim is to keep almost all
+html out of ikiwiki and in the templates.
+
+* `page.tmpl` - Used for displaying all regular wiki pages. This is the
+ key template to customise. [[!if test="enabled(pagetemplate)" then="""
+ (The [[!iki ikiwiki/directive/pagetemplate desc="pagetemplate directive"]]
+ can be used to make a page use a different template than `page.tmpl`.)"""]]
+* `rsspage.tmpl` - Used for generating rss feeds for blogs.
+* `rssitem.tmpl` - Used for generating individual items on rss feeds.
+* `atompage.tmpl` - Used for generating atom feeds for blogs.
+* `atomitem.tmpl` - Used for generating individual items on atom feeds.
+* `inlinepage.tmpl` - Used for displaying a post in a blog.
+* `archivepage.tmpl` - Used for listing a page in a blog archive page.
+* `titlepage.tmpl` - Used for listing a page by title in a blog archive page.
+* `microblog.tmpl` - Used for showing a microblogging post inline.
+* `blogpost.tmpl` - Used for a form to add a post to a blog (and a rss/atom links)
+* `feedlink.tmpl` - Used to add rss/atom links if `blogpost.tmpl` is not used.
+* `aggregatepost.tmpl` - Used by the aggregate plugin to create
+ a page for a post.
+* `searchform.tmpl`, `googleform.tmpl` - Used by the search plugin
+ and google plugin to add search forms to wiki pages.
+* `searchquery.tmpl` - This is a Omega template, used by the
+ search plugin.
+* `comment.tmpl` - Used by the comments plugin to display a comment.
+* `change.tmpl` - Used to create a page describing a change made to the wiki.
+* `recentchanges.tmpl` - Used for listing a change on the RecentChanges page.
+* `autoindex.tmpl` - Filled in by the autoindex plugin to make index pages.
+* `autotag.tmpl` - Filled in by the tag plugin to make tag pages.
+* `calendarmonth.tmpl`, `calendaryear.tmpl` - Used by ikiwiki-calendar to
+ make calendar archive pages.
+* `editpage.tmpl`, `editconflict.tmpl`, `editcreationconflict.tmpl`,
+ `editfailedsave.tmpl`, `editpagegone.tmpl`, `pocreatepage.tmpl`,
+ `editcomment.tmpl` `commentmoderation.tmpl`, `renamesummary.tmpl`,
+ `passwordmail.tmpl`, `openid-selector.tmpl` - Parts of ikiwiki's user
+ interface; do not normally need to be customised.
-Note the use of "raw_name" inside the [[ikiwiki/WikiLink]] generator. This
-ensures that if the name contains something that might be mistaken for wiki
-markup, it's not converted to html before being processed as a
-[[ikiwiki/WikiLink]].
+[[!meta robots="noindex, follow"]]
diff --git a/templates/note.mdwn b/templates/note.mdwn
index 4cc323c..9ef5ad9 100644
--- a/templates/note.mdwn
+++ b/templates/note.mdwn
@@ -1,7 +1,7 @@
<div class="notebox">
<TMPL_VAR text>
</div>
-<TMPL_UNLESS NAME="text">
+<TMPL_UNLESS text>
Use this template to insert a note into a page. The note will be styled to
float to the right of other text on the page. This template has one
parameter:
diff --git a/templates/popup.mdwn b/templates/popup.mdwn
index b355daa..92455eb 100644
--- a/templates/popup.mdwn
+++ b/templates/popup.mdwn
@@ -1,4 +1,4 @@
-<TMPL_UNLESS NAME="mouseover">
+<TMPL_UNLESS mouseover>
Use this template to create a popup window that is displayed when the mouse
is over part of the page. This template has two parameters:
<ul>
diff --git a/wikiicons/openidlogin-bg.gif b/wikiicons/openidlogin-bg.gif
index c8f43d0..a3bfe10 100644
--- a/wikiicons/openidlogin-bg.gif
+++ b/wikiicons/openidlogin-bg.gif
Binary files differ