Creator Tip: Making the table component look different
Some time you must be wondering, why should I use the same looking Table Component as others. Why can't I have different look. The ideal solution would have been, Sun Java Creator IDE providing a Theme Editor. However, ideal solution seldom exists in the real world. In such situation, it is better to look at other alternatives.
One of the solution is to override the properties of the implicit CSS classes used by the Table Component. But how to find these CSS class names. There are two ways to get hold of these names.
I wanted my table to have a different look than the default theme. I have overriden the following CSS styles in the resources/stylesheet.css. The result was a different looking tabe.
table.Tbl {
background-color: #ffcc66;
}
caption.TblTtlTxt {
background-color: #990000;
background-image: none!important;
color: #ffffb4;
font-style: oblique;
font-weight: bolder
}
.TblHdrTxt {
background-image: none!important;
}
table.TblLt .TblHdrTxt {
background-image: none!important;
}
table.Tbl .TblHdrTxt {
background-image: none!important;
font-weight: lighter
}
table.Tbl td, table.Tbl th {
border-color: #ffcc66;
}
table.Tbl th.TblColHdr {
background-color: #ffcc66;
border-color: #f2b741
}
table.Tbl a.TblHdrLnk:link, table.Tbl a.TblHdrLnk:visited {
background-color: #ffcc66;
background-image: none!important;
color: #663389;
font-weight: bold;
}
table.Tbl a.TblHdrImgLnk:link, table.Tbl a.TblHdrImgLnk:visited {
background-color: #ffcc66;
background-image: none!important;
border-color: #f2b741;
}
Posted at 12:59AM Jun 29, 2006 | Permanent link to this entry
Posted by Insider Scoop From the Tutorial Divas on June 29, 2006 at 01:33 PM PDT #
Posted by William on July 17, 2006 at 12:50 PM PDT #
Posted by suganthan on October 05, 2006 at 12:38 AM PDT #
Posted by Annet Vermeer on October 22, 2006 at 07:41 AM PDT #
Posted by Winston Prakash on October 22, 2006 at 05:44 PM PDT #
Posted by Winston Prakash on October 22, 2006 at 05:46 PM PDT #
Posted by Winston Prakash on October 22, 2006 at 05:50 PM PDT #
Posted by Andras Janurik on November 01, 2006 at 02:17 AM PST #
Posted by jaider fernando rodriguez lozano on November 07, 2006 at 05:42 AM PST #
Posted by satish on November 07, 2006 at 09:58 AM PST #
Posted by giorgio on November 21, 2006 at 12:31 AM PST #
Posted by @18@ on December 07, 2006 at 05:23 PM PST #
Posted by Srinivasan1983 on December 08, 2006 at 01:28 AM PST #
Posted by ArthurHung on February 06, 2007 at 02:05 AM PST #
Posted by ArthurHung on February 06, 2007 at 09:28 PM PST #
Posted by Mrinal Khanvilkar on February 20, 2007 at 09:55 PM PST #
Posted by Mrinal Khanvilkar on February 20, 2007 at 09:57 PM PST #
Posted by hamda on May 05, 2007 at 11:31 AM PDT #
Posted by Fernando on July 25, 2007 at 10:01 AM PDT #
Posted by 203.135.8.96 on July 29, 2007 at 11:30 PM PDT #
Posted by Muhammad Waseem Kayani on July 29, 2007 at 11:52 PM PDT #
<html>
<head>
<title>
JSP JSF Code...
</title>
</head>
<body>
<pre>
Sample code :
`````````````
//--------------------------------------------
public HtmlPanelGrid getGridPanel1()
{
for (int i=1; i<6 i++)
{ RadioButtonGroup rbg=this.createRadioButtonGroup(i);
gridPanel1.getChildren().add(rbg);
}
return gridPanel1;
}
//--------------------------------------------
public RadioButtonGroup createRadioButtonGroup(int counter)
{
RadioButtonGroup rbg = new RadioButtonGroup();
Option opt[] = new Option[5];
String rbgID = null;
int i=0;
int k=0;
int rbgValue = 5;
for(int j=0; j<5; j++)
{
opt[i++] = new Option(rbgValue--, choices[k++]);
}
rbgID = "rbg";
rbg.setId(rbgID+counter);
rbg.setColumns(5);
rbg.setItems(opt);
return rbg;
}
//--------------------------------------------
</pre>
</body>
</html>
Posted by 202.147.179.241 on August 20, 2007 at 01:40 AM PDT #
Hi Winston, I am using netbeans 5.5 visual web pack. I have a objectListDataProvider Table in JavaServer Faces .In table there are 3 columns- one of the columns contain TextField,static text and Button name update. I want to set TextField Column of a particular row is enabled after clicking on button.I am trying to do, but If there are more than one records , when i click on update Button , All TextFields of same column are set to enable, disable. I want to set only enable textfield of one row only.. Please Help me... Any help will be appreciated
Posted by chintan anand on October 25, 2007 at 02:58 AM PDT #
you'r the man prakash, you'r great...
Posted by aayohanes on November 02, 2007 at 10:57 PM PDT #
hi my name is maryam.
i have problem when i use jsf-webui and netbeans
when swap page to another page and when came back ,then all pictures in my table lost.
page 1------->page2---------->page1 then my table's picture lost!!!!
my code:
table border="3" background="resources/Image/bt.gif">
<tr>
<td>
test table
</td>
<td>
test table
</td> <td>
test table
</td> <td>
test table
</td>
</tr>
</table>
Posted by Maryam on September 19, 2008 at 02:18 PM PDT #
http://www.batteryfast.co.uk/toshiba/pa2458ur.htm toshiba pa2458ur battery,
http://www.batteryfast.co.uk/toshiba/3020.htm toshiba 3020 battery,
http://www.batteryfast.co.uk/toshiba/3000ct.htm toshiba 3000ct battery,
Posted by laptop battery on October 23, 2008 at 11:44 PM PDT #
i want to create different look of table in visual web java server faces.i also apply the technique which was u display for different look table but its not work properly
Posted by zalak patel on February 09, 2009 at 11:59 PM PST #