Responsive Table Using HTML and CSS





























Hello Developers, We provide you with a dynamic and eye-catching Database table UI design that displays your data with ease. This Database table UI design snippet is created with accuracy using HTML & CSS. Using HTML & CSS, you can create tables that display information efficiently and enhance the user experience using HTML's structure & CSS's styling features. Additionally, you can add hover effects with CSS. This HTML & CSS table snippet is also responsive, which means that your tables are interactive and can be displayed on different devices such as desktop, laptop, tablet, or smartphone. By using this HTML & CSS Table Snippet, you are not only sharing information but also demonstrating your commitment to professionalism and modern web design. Show off & interact with the World with this innovative & creative Database table UI Design Snippet.

How to make Responsive Table Using HTML and CSS.[Source Code]

To make this website, you would like to make two files: an HTML file, a CSS file. First, create an HTML file with the name of index.html and remember, you have to create a file with a .html extension.

<!DOCTYPE html> <html> <head> <title>Table UI design - learningrobo</title> <meta name="description" content="Table UI design - learningrobo"> <meta name="author" content="learningrobo.com"> <meta name="keywords" content="table,responsive,learningrobo.com,html & css projects"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <link rel="icon" type=image/x-icon href="#"> <link rel="stylesheet" href="style.css"> <meta charset="UTF-8"> </head> <body> <!--Hello Future Developer Thanks for Using learningrobo.com, Share & Support us--> <div class="container"> <div class="box"> <table> <tr> <th>ID</th> <th>First Name</th> <th>Designation</th> <th>Gender</th> <th>Salary</th> <th>Alive</th> </tr> <tr> <td>1</td> <td>Henry</td> <td>Web Designer</td> <td>M</td> <td>Rs. 30,000</td> <td>Yes</td> </tr> <tr> <td>2</td> <td>Joe</td> <td>Web Developer</td> <td>M</td> <td>Rs. 35,000</td> <td>Yes</td> </tr> <tr> <td>3</td> <td>Roosie</td> <td>Graphics Designer</td> <td>F</td> <td>Rs. 20,000</td> <td>Yes</td> </tr> <tr> <td>4</td> <td>Taylor</td> <td>Digital marketing</td> <td>F</td> <td>Rs. 40,000</td> <td>Yes</td> </tr> <tr> <td>5</td> <td>Bery</td> <td>Content Writer</td> <td>M</td> <td>Rs. 15,000</td> <td>Yes</td> </tr> <tr> <td>6</td> <td>Cathelin</td> <td>Website manager</td> <td>F</td> <td>Rs. 45,000</td> <td>Yes</td> </tr> <tr> <td>7</td> <td>Sigoon</td> <td>Project Director</td> <td>M</td> <td>Rs. 50,000</td> <td>Yes</td> </tr> <tr> <td>8</td> <td>Vatsan</td> <td>Social media analyst</td> <td>M</td> <td>Rs. 20,000</td> <td>Yes</td> </tr> </table> <div class="credit">Made with <span>❤ </span>by <a href="https://www.learningrobo.com/"> learningrobo</a></div> </div> </div> <!--Check our website Regularly For New Snippets Post--> </body> </html>
CSS provides style to an HTML page. To make the page attractive create a CSS file with the name style.css and remember that you have to make a file with a .css extension.


/** 
Hello Future Developer Thanks for Using learningrobo.com, 
Check our website Regularly For New Snippets Post.

Share & Support us
**/
*{
    box-sizing: border-box;
}
body{
    margin:0px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}
.container{
    width:100%;
    min-height:100vh;
    max-height:fit-content;
    display:flex;
    justify-content:center;
    flex-direction: column;
    align-items:center;
    background-color:#00576B;
}
.box{
    background-color:#012C3C;
    width: 850px;
    height: 500px;
    margin: 110px auto;
}
table,th,td{
    border: none;
    border-collapse: collapse;
}
table{
    width: 850px;
    height: 500px;
    font-size: 18px;
    color:#ffff;
}
th{
    background-color:#012C3C;
    color: rgb(209, 209, 13);
    padding-left: 10px;
    text-align: left;
}
td{
    padding-left: 10px;
}
tr:nth-child(even){
    background-color: #05425895;
}
tr:hover{
    background-color:rgba(84, 152, 167, 0.324);
    transition:.5s;
}
@media screen and (max-width:1024px){
    .box{
        width:85%;
        height:fit-content;
    }
    table{
        width: 100%;
        height: 500px;
    }
}
@media only screen and (max-width: 630px){
    .box{
        margin:10px 0px;
        width:95%;
        height:fit-content;
    }
    table{
        width: 100%;
        height: 500px;
    }
    .box th{
        display: none;
    }
    .box td{
        display:grid;
        grid-template-columns:15ch auto;
        text-align: left;
        padding:5px;
        margin:5px;
        border:none;
    }
    .box td:nth-of-type(1)::before{
        content: "ID" " :";
    }
    .box td:nth-of-type(2)::before{
        content: "First Name" " :";
    }
    .box td:nth-of-type(3)::before{
        content: "Designation" " :";
    }
    .box td:nth-of-type(4)::before{
        content: "Gender" " :";
    }
    .box td:nth-of-type(5)::before{
        content: "Salary" " :";
    }
    .box td:nth-of-type(6)::before{
        content: "Alive" " :";
    }
}
.credit a{
    text-decoration: none;
    color: #ffff;
    font-weight: 800;
}
.credit{
    color: #ffff;
    text-align: center;
    margin-top: 10px;
    font-family: Verdana,Geneva,Tahoma,sans-serif;
}
.credit span{
    color:tomato;
    font-size:20px;
}
We hope you would like this Responsive Table Using HTML and CSS.

Thank you for reading our blog. If you face any problem in Creating a Responsive Table Using HTML and CSS., then contact us or comment to us. We’ll try to provide a solution to your problem as soon as possible.

Press The Key ' p ' and say ' read article ' our voice assistant read our article.
In Our older post it doesnot work we working on that.

Thank you
Learning robo team

إرسال تعليق

Thank you
Learning robo team

Post a Comment (0)

أحدث أقدم
Learning Robo says...
code copied
Welcome