Innehållsförteckning

button Plugin

Compatible with DokuWiki

  • 2025-05-14 "Librarian" yes
  • 2024-02-06 "Kaos" yes
  • 2023-04-04 "Jack Jackrum" yes
  • 2022-07-31 "Igor" yes

plugin Create buttons for links

Last updated on
2025-03-29
Provides
Syntax
Repository
Source
Conflicts with
siteexport

Similar to bootswrapper, mikioplugin, wrap

Tagged with button, links

Installation

Search and install the plugin using the Extension Manager. Refer to Plugins on how to install plugins manually.

Examples/Usage

Below is a screenshot of a basic resulting button:

Syntax

The full syntax is:

[[{namespace:image|extra css}wiki page|**Title** of the link]]

Where:

All fields are optional, so the minimal syntax is:

[[{}Simple button without image]]

You may configure some styles to use in your buttons without repeating all the css:

[[{conf.styles}style|css]]

Where:

You may then use the style in your button, example:

Style declaration:
[[{conf.styles}default|font-family: "Times New Roman", Times, serif;]]
[[{conf.styles}mystyle|color:green; width:15em;]]

Style use:
[[{|mystyle}Button in times new roman]]
[[{}Button in green and in times new roman]]

You may also add styles that will be available for all pages in the plugin section of the configuration page. You will have to add one line per style:

default|font-family: "Times New Roman", Times, serif;
mystyle|color:green; width:15em;

Note that the CSS part is a bit tricky due to the selectors used in the template CSS and the layout needed for the button. By default, the style of the links is not repeated (just external links icon). See comments in style.css file for more information.

You may also configure the target of the link with the use of conf.target:

[[{conf.target}style|target]]

Example:

[[{conf.target}default|_blank]]

A button is added to the toolbar to add the template button. Compatible with move plugin.

Center Button

[[{buttons:fbreader.png|width: 25em; display: table; margin: 0 auto; }tototp|Centered button]]


Troubleshooting

Contributions

Feel free to contribute to this plugin source on GitHub: https://github.com/rpeyron/plugin-button

Thank you to:

Changelog

Request

If you have any request, please add an issue to https://github.com/rpeyron/plugin-button/issues

Older requests: