Open In App

Top 5 HTML Tricks That You Should Know

Being a developer we all want to display attractive things to the user, that must be useful also. In this article, we will discuss such tricks that will make your development enjoyable. All the tricks are described below with the proper example.
HTML top 5 tricks and tips: 
 






<!DOCTYPE html>
<html>
    <head>
        <title>Color picker in input field</title>
        <style>
            .container {
                text-align: center;
            }
             
            h1 {
                color: green;
            }
        </style>
    </head>
    <body>
        <div class="container">
        <h1>GeeksforGeeks</h1>
        <b>Color picker in input filed: </b>
        <input type="color">
        </div>
    </body>
</html>




<!DOCTYPE html>
<html>
    <head>
        <title>Document Refresher</title>
        <meta http-equiv="refresh" content="10">
        <style>
            .container {
                text-align: center;
            }
             
            h1 {
                color: green;
            }
        </style>
    </head>
    <body>
        <div class="container">
        <h1>GeeksforGeeks</h1>
        <b>Document will refresh after 10sec</b>
        </div>
    </body>
</html>






<!DOCTYPE html>
<html>
    <head>
        <title>Theme color changer</title>
        <meta name="theme-color" content="#26F809">
        <style>
            .container {
                text-align: center;
            }
             
            h1 {
                color: green;
            }
        </style>
    </head>
    <body>
        <div class="container">
        <h1>GeeksforGeeks</h1>
        <b>Theme color changer</b>
        </div>
    </body>
</html>




<!DOCTYPE html>
<html>
    <head>
        <title>Icon adder</title>
        <meta name="theme-color" content="green;">
        <link rel="icon" href="/icon.ico"
                     type="image/x-icon"/>
        <style>
            .container {
                text-align: center;
            }
             
            h1 {
                color: green;
            }
        </style>
    </head>
    <body>
        <div class="container">
        <h1>GeeksforGeeks</h1>
        <b>Icon adder</b>
        </div>
    </body>
</html>                   




<!DOCTYPE html>
<html>
    <head>
        <title>Voice recognition</title>
        <style>
            .container {
                text-align: center;
            }
             
            h1 {
                color: green;
            }
        </style>
    </head>
    <body>
        <div class="container">
        <h1>GeeksforGeeks</h1>
        <b>Voice recognition</b>
        <input type="text" x-webkit-speech>
        </div>
    </body>
</html>                   


Article Tags :