-2

Click here to view structure

Each table cell is identified with a letter and all dimensions are in pixels. The letters and dimensions shown in the table must NOT appear on your final web page. The external table border must have a width of 4 pixels and all internal grid lines on the table must have a width of 2 pixels. Table borders and grid lines must be visible.

<!DOCTYPE html>
<html>

<head>
    <title> Nested Table </title>
</head>

<body>

    <table border="4px" align="center" width=100%>

        <tr>
            <td height="300px" width="400px"> A 400 X 300 </td>
            <td height="300px" width="400px"> B 400 X 300 </td>
            <td height="300px" width="400px"> C 400 X 300 </td>
        </tr>

        <tr>
            <td colspan=3 height="250px" width="1200px"> D 1200 X 250 </td>
        </tr>

        <tr>
            <td colspan=3 height="150px" width="1200px"> E 1200 X 150 </td>
        </tr>
        <tr>
            <table border="4" align="center">
                <tr>
                    <td height="300px" width="50%"> F 600 X 300 </td>
                    <td height="300px" width="600px"> G 600 X 300 </td>
                </tr>
        </tr>
        </table>

</html>
  • I'm sorry, this might sound a bit arrogant. But what kind of site do you think this is? I think you might be looking for freelancer.com or fiverr.com – manneJan89 May 22 '20 at 19:19
  • No no that's completely fine. This que is asked by our faculty which I couldn't solve as I'm a beginner. I'm trying since morning so I thought let's see if somebody can help me. – Sudarshan Bhamare May 22 '20 at 19:24
  • What have you tried? If you are struggling with your brief, I think you should ask your faculty leaders for help instead. SO is for devs helping each other out, not for doing your work for you. – manneJan89 May 22 '20 at 19:26
  • 1
    If you are really struggling, post what you have tried and we will point you in the right direction. Nobody is going to do the work for you. – manneJan89 May 22 '20 at 19:27
  • but it's just a simple structure any pro can solve within hour minutes maybe. What wrong with it. – Sudarshan Bhamare May 22 '20 at 19:30
  • If other devs keep doing your work for you, how are you going to learn? As I said, post what you have done and we will point you in the right direction. – manneJan89 May 22 '20 at 19:36
  • please check the code and let me know where should I correct myself. Thank You. – Sudarshan Bhamare May 22 '20 at 19:36
  • jae.phoenix it would be my pleasure if you see my code and let me know the correction or a complete solution. Thank You in advance. – Sudarshan Bhamare May 22 '20 at 19:53

1 Answers1

0

tr:first-child td{
height:100px;
width:100px;
}
tr:nth-child(2) td{
height:60px;
}
tr:nth-child(3) td{
height:40px;
}
tr:nth-child(4) td{
height:100px;
width:50%;
}
<table border="1">
<tr>
 <td>
 </td>
 <td>
 </td>
 <td>
 </td>
</tr>
<tr>
 <td colspan = "3">
 </td>
</tr>
<tr>
 <td colspan = "3">
 </td>
</tr>
<tr>
 <td colspan = "2">
 </td>
 <td>
 </td>
</tr>
</table>
Avinash Dalvi
  • 8,551
  • 7
  • 27
  • 53