Basic HTML Version

|  | Table of Contents |  | View Full Version

Page 59 - 2625 PortGPt V2.1
P. 59

    Border-Collapse Property
                     The border-collapse property in the <style> tag is used to create a single border for the table cells.

                                Property                        Value                          Description

                                                      separate                    Applies separate border for each cell.
                      border-collapse
                                                      collapse                    Applies single border for each cell.

                     <!DOCTYPE html>
                     <HTML>

                     <HEAD>
                     <TITLE>A Simple Table Structure</TITLE>
                     <BODY>
                     <STYLE>
                     TABLE, TH, TD

                     {
                     Border:2px solid black;
                     Border-collapse:collapse;
                     }

                     </STYLE> </HEAD><TABLE>
                     <CAPTION>STUDENT'S DETAILS</CAPTION>
                     <TR>
                         <TH>ADMISSION</TH>
                         <TH>NAME</TH>
                         <TH>TOTAL MARKS</TH>

                     </TR>
                     <TR>
                         <TD>2016/0256</TD>
                         <TD>Aadya Kaushal</TD>

                         <TD>589</TD>
                     </TR>
                     <TR>
                         <TD>2017/0865</TD>
                         <TD>Shweta Kaushal</TD>

                         <TD>545</TD>
                     </TR>
                     </TABLE>
                     </BODY>
                     </HTML>

                                                                                                  Introduction to CSS3  57

| 54 55 56 57 58 59 60 61 62 63 64 |