|
Parameters | Accepted Values | Description | Default | Since |
---|---|---|---|---|
(body of plugin) | Label for the button (ignored if the text is defined) | |||
href |
url | URL to be produced by the button. For Wiki page uses Page Name format. You can use wiki argument variables like
in it |
6.1 | |
height |
text | In pixels or percentage. (e.g. 200px or 100%) | 20 | |
width |
text | In pixels or percentage. (e.g. 200px or 100%) | 20 | |
_class |
text | CSS class for the button. Note that the btn class is always applied by default | 6.1 | |
_style |
text | CSS style attributes | 6.1 | |
_icon_name |
text | Enter an iconset name to show an icon in the button | 14.0 | |
_text |
text | Label for the button | 6.1 | |
_rel |
text | Enter box for colorbox effect (like shadowbox and lightbox) or appropriate
syntax for link relation. |
7.0 | |
_auto_args |
text | Comma-separated list of URL arguments that will be kept from _REQUEST (like
$auto_query_args ) in addition to those you can specify in the href parameter.You can also use _auto_args="*" to specify that every arguments listed in the
global var $auto_query_args has to be kept from URL |
6.1 | |
_type |
(blank) danger default info link primary success warning |
Use a type to style the button. By default btn-primary will be applied. | 13.0 | |
data |
text | URL encoded list or attributes and values. | 20.2 | |
_disabled |
alpha | Set to y to disable the button |
6.1 | |
_flip_id |
alpha | HTML id attribute of the element to show/hide content | 6.1 | |
_target |
(blank) _blank _parent _top |
A target attribute specifies where to open the linked document. Set to _self by default | 21.0 | |
_escape |
(blank) y n |
If set to y , will escape the apostrophes in onclick |
6.1 | |
_flip_default_open |
(blank) y n |
If set to y , the flip is open by default (if no cookie jar) |
6.1 | |
_flip_hide_text |
(blank) y n |
If set to No (n ), will not display a "(Hide)" suffix after the button label
when the content is shown |
6.1 |
This code:
{button href="Home?itemId=" _text="Go there" _type="danger" _icon_name="wrench"}
Would produce on this site:
A button with the "Go there" as label, and the wiki argument variable replaced by the itemId passed in the url of the page where this plugin button is located:
This code:
{button href="HomePage" _rel="box" _text="Go there"}
Will create a button that opens the HomePage in a colorbox:
Since Tiki 19, this code:
{button href="HomePage" _icon_name="home" _type="primary"} {button href="Edit" _icon_name="pencil" _type="primary"} {button href="Delete" _icon_name="trash" _type="danger"}
Will create a set of buttons with icons only:
Since Tiki 20.2, this code:
{button href="HomePage" _class="click-modal" data="modal-submit-redirect-url=/success-page"}
Will load the href URL in a modal, and redirect to the URL given in the data attribute once the form (if any) within the modal is submitted.
Setting parameter type to none allow full customization using your own style for a button. (it remove default btn-xxx style)
Using this code
{button href="#thispage" _text="This is a button from type : none" _type=" "}
Will display this (a button without any style)
This is a button from type : none
{button href="((HomePage))" _text="Go there"}