<button>: The Button element
- The HTML element button> depicts a clickable button that may be used to submit forms or to provide typical button functionality anywhere in a document.
- HTML buttons are styled to match the platform the user agent is running on by default, but you may modify their appearance with CSS.
- Add the following code.
<div>
<html>
<head>
<meta content="width=device-width, initial-scale=1" name="viewport"></meta>
<style>
.button {
border-radius: 20px;
background-color: #f4511e;
border: none;
color: #FFFFFF;
text-align: center;
font-size: 28px;
padding: 20px;
width: 200px;
transition: all 0.5s;
cursor: pointer;
margin: 5px;
}
.button span {
cursor: pointer;
display: inline-block;
position: relative;
transition: 0.5s;
}
.button span:after {
content: '\00bb';
position: absolute;
opacity: 0;
top: 0;
right: -20px;
transition: 0.5s;
}
.button:hover span {
padding-right: 25px;
}
.button:hover span:after {
opacity: 1;
right: 0;
}
</style>
</head>
<body>
<a href="https://mskuthar.blogspot.com/"><button class="button"><span>Next</span></button></a>
</body>
</html>
</div>
<html>
<head>
<meta content="width=device-width, initial-scale=1" name="viewport"></meta>
<style>
.button {
border-radius: 20px;
background-color: #f4511e;
border: none;
color: #FFFFFF;
text-align: center;
font-size: 28px;
padding: 20px;
width: 200px;
transition: all 0.5s;
cursor: pointer;
margin: 5px;
}
.button span {
cursor: pointer;
display: inline-block;
position: relative;
transition: 0.5s;
}
.button span:after {
content: '\00bb';
position: absolute;
opacity: 0;
top: 0;
right: -20px;
transition: 0.5s;
}
.button:hover span {
padding-right: 25px;
}
.button:hover span:after {
opacity: 1;
right: 0;
}
</style>
</head>
<body>
<a href="https://mskuthar.blogspot.com/"><button class="button"><span>Next</span></button></a>
</body>
</html>
</div>
It will produce following output.