• Post Reply Bookmark Topic Watch Topic
  • New Topic

how to align a panelGrid ?  RSS feed

 
v ray
Ranch Hand
Posts: 223
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi guys,

I have a panelGrid which contains description of a particular service provider. If I want this panelGrid to be displayed to left of the page, how would I do it?
Ie, I want some sort of an equivalent to:
<table align="left">

Any ideas?
Would this work?

 
Ronald Aguilar
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
use the styleClass to manipulate the fonts, colors and alignment by defining them in the css file.
 
v ray
Ranch Hand
Posts: 223
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So I create a .css file which has contents like:

<style>
.alignRight
{
text-align:right;
}

</style>

so, once I create this file, I use the code below and it would work?
How do I refer to the .css file in the jsf page to make this work?

<h:panelGrid columns="1" columnClasses="alignRight">
....
</h:panelGrid>
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!