Bootstrap Button Link Shortcode

Shortcode to generate button link.

Syntaxes

Closing Syntax

1{{< bs/btn-link >}}
2TEXT
3{{< /bs/btn-link >}}

Recommended for rich button text, it’s useful for the case of nesting shortcodes, such as ico.

Self-Closing Syntax

1{{< bs/btn-link text=TEXT />}}

Recommended for plain button text.

Parameters

url

PositionNameTypeRequiredDefaultSinceExample
#0urlstring---

The URL or reference of button link, it’ll look for the reference page first for internal pages.

style

PositionNameTypeRequiredDefaultSinceExample
#1stylestring-primary--

The button link style: primary, secondary, success, danger, warning, info, light, dark, link.

outline

PositionNameTypeRequiredDefaultSinceExample
#2outlinestring-false--

Whether to enable outline style.

size

PositionNameTypeRequiredDefaultSinceExample
#3sizestring----

The size of button link: sm, lg.

class

PositionNameTypeRequiredDefaultSinceExample
-classstring----

Used to add extra CSS classes.

Examples

Source
1{{< bs/btn-link url="#self-closing-button-link" text="Self-Closing" />}}
Source
1{{< bs/btn-link url="#closing-button-link" >}}
2Closing {{< ico vendor=bs name=x-circle >}}
3{{< /bs/btn-link >}}
Result
Closing
Source
 1{{< bs/btn-link "#button-link-styles" "primary" >}}
 2Primary
 3{{< /bs/btn-link >}}
 4
 5{{< bs/btn-link url="#button-link-styles" style="secondary" text="Secondary" />}}
 6
 7{{< bs/btn-link "#button-link-styles" "success" >}}
 8Success
 9{{< /bs/btn-link >}}
10
11{{< bs/btn-link "#button-link-styles" "danger" >}}
12Danger
13{{< /bs/btn-link >}}
14
15{{< bs/btn-link "#button-link-styles" "warning" >}}
16Warning
17{{< /bs/btn-link >}}
18
19{{< bs/btn-link "#button-link-styles" "info" >}}
20Info
21{{< /bs/btn-link >}}
22
23{{< bs/btn-link "#button-link-styles" "light" >}}
24Light
25{{< /bs/btn-link >}}
26
27{{< bs/btn-link "#button-link-styles" "dark" >}}
28Dark
29{{< /bs/btn-link >}}
30
31{{< bs/btn-link  "#button-link-styles" "link" >}}
32Link
33{{< /bs/btn-link >}}
Source
1{{< bs/btn-link url="#outline-button-link" outline=true >}}
2Primary outline button link
3{{< /bs/btn-link >}}
Source
 1{{< bs/btn-link url="#button-link-sizes" size=sm >}}
 2Smaller button link size
 3{{< /bs/btn-link >}}
 4
 5{{< bs/btn-link url="#button-link-sizes" >}}
 6Normal button link size
 7{{< /bs/btn-link >}}
 8
 9{{< bs/btn-link url="#button-link-sizes" size=lg >}}
10Lager button link size
11{{< /bs/btn-link >}}
Source
1{{< bs/btn-link url="#button-link-with-extra-classes" size=lg class="d-block py-3 rounded-0" >}}
2Button link with extra classes
3{{< /bs/btn-link >}}
Source
1{{< bs/btn-link "https://hbstack.dev/" >}}
2HB Framework (external)
3{{< /bs/btn-link >}}
4
5{{< bs/btn-link "docs/installation" >}}
6Installation (internal)
7{{< /bs/btn-link >}}