Html Button
Here's an example of how to create a basic HTML button:
Button with ID and Class:
<button id="myButton" class="btn">Submit</button>
Button with onclick Event:
<button onclick="myFunction()">Click Me</button>
Disabled Button:
<button onclick="myFunction()">Click Me</button>
Button with Custom Styling:
<button style="background-color: blue; color: white;">Styled Button</button>
Button with Link:
<button onclick="location.href='https://example.com';">Go to Example</button>
Reset Button:
<button type="reset">Reset</button>
Button with Icon:
<button><i class="fa fa-home"></i> Home</button>
Button with Form Interaction:
<form action="/submit" method="post"> <button type="submit">Submit Form</button> </form>
Post a Comment