Results 1 to 3 of 3
  1. #1
    aruna is offline Freshman
    Join Date
    Mar 2011
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Feedback Score
    0

    Default hi., i have to know about<colgroup> tag with code, how it works .,

    i have to know about<colgroup> tag with code and how it works .,whether, it may useful for creating a table in a better way.,

  2. #2
    manik's Avatar
    manik is offline Om Shanti!
    Join Date
    Apr 2008
    Location
    Boston, USA
    Posts
    13,176
    Thanks
    744
    Thanked 701 Times in 550 Posts
    Blog Entries
    4
    Feedback Score
    4 (100%)

    Default

    <colgroup> tag applies to table and is used to group columns in a table for formatting.
    <colgroup> tag is useful for applying styles to entire columns, instead of repeating the styles for each cell, for each row.
    <colgroup> tag can only be used inside a table element.

    Example(w3 school):
    Two colgroup elements that specify different alignment and style for the three columns in the table (notice that the first colgroup element spans two columns):
    <table width="100%" border="1">
    <colgroup span="2" align="left"></colgroup>
    <colgroup align="right" style="color:#0000FF;"></colgroup>
    <tr>
    <th>ISBN</th>
    <th>Title</th>
    <th>Price</th>
    </tr>
    <tr>
    <td>3476896</td>
    <td>My first HTML</td>
    <td>$53</td>
    </tr>
    </table>
    Free Classified Ads & BUSINESS/PROFESSIONAL SOCIAL NETWORK


  3. #3
    jacobatwood is offline Sophomore
    Join Date
    Mar 2011
    Posts
    90
    Thanks
    0
    Thanked 1 Time in 1 Post
    Feedback Score
    0

    Default

    The HTML <colgroup> tag is used for specifying properties for a group of columns within a table.
    If you need to apply different properties to a column within a <colgroup>, you can use the HTML col tag within the <colgroup> tag.
    e.g.


    <table border="1">
    <colgroup span="3">
    </colgroup>

    <tr>
    <td>col 1</td>
    <td>col 2</td>
    <td>col 2</td>
    </tr>
    </table>

    It's attributes are-
    span-Specifies how many columns to span.
    Width-Width of the column.

Similar Threads

  1. How Alexa works?
    By sarita in forum All Other Search Engines
    Replies: 11
    Last Post: 09-26-2011, 03:49 AM
  2. Article about STOP Code 0x1 to STOP Code 0x5F
    By hitech in forum Computer and Tech
    Replies: 0
    Last Post: 08-21-2010, 01:33 AM
  3. Convert VB .Net Code to C# .Net Code
    By manik in forum ASP
    Replies: 0
    Last Post: 12-19-2008, 11:24 AM
  4. How Google Works?
    By Amit.Verma in forum Google
    Replies: 1
    Last Post: 08-29-2008, 08:56 AM
  5. What works best for you?
    By wujijiangjun in forum General Marketing
    Replies: 7
    Last Post: 06-10-2008, 11:54 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Partners: BOSTON WEB DEVELOPER, LLC   |   WEBCOSMO CLASSIFIEDS