Hypertext links to files on the local file system are specified using the link inline macro.
link:<target>[<caption>]
The link macro generates relative URLs. The link macro <target>
is
the target file name (relative to the file system location of the
referring document). The optional <caption>
is the link’s displayed
text. If <caption>
is not specified then <target>
is displayed.
link:get-started.html[]
Renders:
link:get-started.html[Start]
Renders:
If you want more enhancement and focus on specific link, you want probably to use buttons links as provided by Bootstrap.
It’s now possible with this major version 3 of AsciiDoc-Bootstrap backend.
Let’s restart our example, with the single link, and apply it a button style.
link:get-started.html[role="primary"]
Renders:
Change the text
link:get-started.html["Start Tour",role="primary"]
or with alternative
link:get-started.html[caption="Start Tour",role="primary"]
Renders:
![]() | |
You have certainly understood that all button color style may be applied with the |
You want probably more than just a button. Adding an icon will improve again more the look and feel !
link:get-started.html["Start Tour",role="info",icon="glyphicon-play-circle"]
Renders:
![]() | |
Icons are named with prefix glyphicon on Bootstrap 3, and with prefix icon on Bootstrap 2. |
And finally, choose what side you want to put your icon.
link:get-started.html["Whats wrong",role="danger",icon="glyphicon-remove-circle",options="right,white"]
Renders:
![]() | |
On Bootstrap 2 icon color are black by default. So add white option to change it. This option is useless on Bootstrap 3. |