Website Development & Management CIT 3353 -- Fall 2006 www.clt.astate.edu/jseydel/mis3353 Website Development & Management Some HTML Table Basics Instructor: John Seydel, Ph.D.
Student Objectives Upon completion of this class meeting, you should be able to: Create simple HTML tables Modify the primary style aspects for HTML tables
HTML Tables Used traditionally for layout Control placement of content Yielding in favor of style sheets Together with HTML forms, tables are essential components of eCommerce sites Element hierarchy: Top level: <table> Second level: row <tr> Bottom level: column or cell <td> or <th> Note: Prior planning is a must !
A Simple 2x2 Table <table class=“tablemain”> <tr> <th>11</th> <th>12</th> </tr> <td>11</td> <td>12</td> <td>21</td> <td>22</td> </table>
Style Attributes to Modify Note: attributes within table elements have been deprecated; therefore, use style rules Background Color Image Alignment Table Cell contents Width (default is pixels, unless %) Height (default is pixels, unless %) Spacing Border Cell Padding