Posts

Showing posts with the label table

How to Create a table in html with 2 rows and 3 columns (Source code )

Image
How to Create a table in html with 2 rows and 3 columns (Source code ) <html> </body> <!-- CSS Code: Place this code in the document's head (between the 'head' tags) --> <head> <title> 2 rows and 3 columns |  2*3 Row and column in HTML Source code  </title> <style> table.techthinkforu {   width: 100%;   background-color: #ffffff; border-collapse: separate;   border-width: 2px;   border-color: #2b2a27;   border-style: solid;   color: #121212; } table.techthinkforu td, table.techthinkforu th {   border-width: 2px;   border-color: #2b2a27;   border-style: solid;   padding: 3px; } table.techthinkforu thead {   background-color: #eae6d7; } </style> </head> <!-- HTML Code: Place this code in the document's body (between the 'body' tags) where the table should appear --> <table class="techthinkforu">   <thead>     <tr>     ...

table hover background color css

 table hover background color css <head> <style> tr:hover  { background-color:#f5f5f5; }  </style>  </head>  <body>  ​ <h2>Hoverable Table</h2>  <p>Move the mouse over the table rows to see the effect.</p> Full Source code of  table hover background color css <html> <head> <style> table {   border-collapse: collapse;   width: 100%; } th, td {   padding: 8px;   text-align: left;   border-bottom: 1px solid #ddd; } tr:hover { background-color:#f5f5f5; } </style> </head> <body> <h2>Hoverable Table</h2> <p>Move the mouse over the table rows to see the effect.</p> <table>   <tr>     <th>First Name</th>     <th>Last Name</th>     <th>Points</th>   </tr>   <tr>     <td>Peter</td>     ...

table background-color css

 table background-color css <html> <head> <style> #customers  {   font-family: Arial,   Helvetica, sans-serif;   border-collapse: collapse;   width: 100%; } #customers td,  #customers th  {   border: 1px solid  #ddd;    padding: 8px; } #customers tr:nth-child(even) { background-color: #f2f2f2 ; } #customers tr:hover  { background-color: #ddd; } #customers th  {   padding-top: 12px;   padding-bottom: 12px;   text-align: left;   background-color: #04AA6D;   color: white; } </style> </head> <body> <table id="customers">   <tr>     <th>Company</th>     <th>Contact</th>     <th>Country</th>   </tr>   <tr>     <td>Alfreds Futterkiste</td>     <td>Maria Anders</td>     <td>Germany</td>   ...

table background color in html

 table background color in html <table>   <tr style="background-color:#FF0000">     <th>Month</th>     <th>Savings</th>   </tr>   <tr>     <td>feb</td>     <td>$200</td>   </tr>  </table> 

Why TD is used in HTML?

 Why TD is used in HTML? HTML <td> tag .  When writing in HTML, the <td> tag is used to designate a cell (table data) within a table containing data.  The information contained in this element is left-aligned by default. How to use <td> tag in table in html <tr > <td> first </td>  <td>Second</td> </tr>

What does TR mean in HTML?

 What does TR mean in HTML? TR meaning in HTML when we are making table the  we use < tr > tag TR stand for table row  How we use < tr > tag in table  <tr> The Table Row element </tr>  element defines a row of cells in a table.

How do I bold a < table > data in HTML?

How do I bold a < table > data in HTML? <td> <span style="font-weight: bold ">bold text</span></td> <td><span class="nam">Name text you want bold</span> rest of your text</td> Style with CSS for table data : .nam { font-weight: bold; }

How do you add color to a < table > in HTML?

Image
 How do you add color to a < table > in HTML? <style type="text/css">   table          {border:ridge 5px red;}   table td       {border:inset 1px #000;}   table tr #ROW1  {background-color:red; color:white;}   table tr #ROW2  {background-color:white;}   table tr #ROW3  {background-color:blue; color:white;}   table td #CELL9 {border:inset 4px red; background-color:navy;} </style> <table>       <tr id="ROW1"> <td>Cell 1.1</td> <td>Cell 1.2</td> <td>Cell 1.3</td>   </tr>         <tr id="ROW2"> <td>Cell 2.1</td> <td>Cell 2.2</td> <td>Cell 2.3</td>   </tr>         <tr id="ROW3"> <td>Cell 3.1</td> <td>Cell 3.2</td <td id="CELL9">Cell 3.3</td>   </tr> ...

How do you put a border on a < table >?

 How do you put a border on a < table >? To add a border to your table, you need to define the  <style> of your table <!DOCTYPE html> <html>   <head>     <title>Title of the document</title>       <style>       table {         border-style: ridge;         border-width: 150px;         border-color: #8ebf42;         background-color: #d9d9d9;       }       th {         border: 5px solid #095484;       }       td {         border: 20px groove #1c87c9;       }     </style>   </head>   <body>     <table>       <tr>         <th>Person</th>         <th>Age</th> ...

What is the use of tables in HTML?

 What is the use of tables in HTML? The HTML table model allows authors to arrange data -- text, preformatted text, images, links, forms, form fields, other tables, etc. -- into rows and columns of cells. Each table may have an associated .

< table > in HTML (Source code)

A Simple Table example in HTML   Each table row is defined with a <tr> tag table header is defined with a <th> tag  the text in <td> elements are regular and left-aligned   The <table> tag defines an HTML table    <table style="width:100%">   <tr>     <th>First Name</th>     <th>Last Name</th>     <th>Age</th>   </tr>   <tr>     <td>Tech</td>     <td>Forum</td>     <td>1</td>   </tr>   <tr>     <td>Arya</td>     <td>Jhon</td>     <td>59</td>   </tr> </table>