CSS Classes
Changing the Style of Wiki Links
When rendered on the viewed page, wiki links are given a CSS class related to their post status (published, draft, etc). You can override the default colors in your style sheet. This is a convenience for those with edit permissions who might not realize that wiki articles have not been published. Note that WordPress permissions still control what posts can actually be viewed, this is just related to the display of wiki links. The classes are:
When viewing links for users with the “edit_posts” capacity:
- .wikilink-new (post does not exist – a link to create it)
- .wikilink-trash (post is in the trash – just text, no link)
- .wikilink-pending (post has the status of “draft”, “auto-draft”, “pending”, or “future” – a regular link)
- .wikilink-private (post has a status of “private” – a regular link)
- .wikilink-published (the post is published – a regular link)
- .wikilink-other (default if not one of the above. Applied to posts with a custom post status or to those with a status of “inherit” – a regular link)
When viewing links for users without the “edit posts” capacity:
- .wikilink-no-edit (post does not yet exist or the post has the status of “trash”, “draft”, “auto-draft”, “pending”, or “future” – just text, no link)
- .wikilink-published (the post is published – a regular link)
- .wikilink-private (post has a status of “private” – a regular link)
- .wikilink-other (default if not one of the above. Applied to posts with a custom post status or to those with a status of “inherit” – a regular link)