Buttons are the elements you can use for form submission and get user input data. By default, the buttons do not contain a link to redirect to the web page. However, create anchor link button requires more CSS to apply on it and get a button like structure.

Bootstrap buttons provide many classes to create a button link. To create your own anchor link button, you have to use the class .btn and .btn-primary as the class of the <a> tag.

Below is the example showing the anchor link button using the Bootstrap classes.

Output

Bootstrap Button

Click the above button and it will redirect you to the other page location. This is useful when you want your button to not to submit a form and instead of this, it will redirect to the other website page or your website internal page.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.