Basic HTML Version

|  | Table of Contents |  | View Full Version

Page 116 - 2626_South Point_C-7
P. 116

    Using background-color Property

                      The background-color property is used to specify the colour of the background in a table on the web
                      page. You can apply colour in a cell, row or entire table.
                      For example,

                        <STYLE>
                        table, th, td
                        { border:2px;
                        border-style:solid;

                        border-color:green;
                        background-color:orange; }
                        </STYLE>

                                                                                 Using background-color Property

                      Using color Property

                      The color property is used to specify the text colour. For example,

                        <STYLE>
                        table, th, td
                        { border:2px;

                        border-style:solid;
                        border-color:green;
                        background-color:orange;
                        color:blue; }
                        </STYLE>
                                                                                       Using color Property

                      Creating a table using all the table tags above.

                            <STYLE>
                                table, th, td {
                                    border: 2px solid green;
                                    border-style: dashed;
                                    background-color: pink;
                                    color: blue;
                                    border-spacing: 15px;
                                    width: 40%;
                                    height: 50px;
                                }
                        td{ padding:10px; }
                            </STYLE>

                      114   Premium Edition-VII

| 111 112 113 114 115 116 117 118 119 120 121 |