Help coderanch get a
new server
by contributing to the fundraiser
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

How to get blank underlined line in jsf?

 
Ranch Hand
Posts: 58
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have tried this but got only blank spane without underline

 
Saloon Keeper
Posts: 27933
198
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Your problem is not JSF, it is the HTML that JSF generates.

HTML is unlike PostScript (PDF) format in that the layout information is only a suggestion rather than absolute, and one of the ways you can see this is in what it does with space characters on the page.

There are a couple of ways to get a horizontal line on a web page in HTML (and thus in JSF). The most basic one is the <hr/> tag. By default, however, this won't be an underline, it will be a line approximately midway up in the current row.

Another way is to use an image tag to pull in an image of a blank underline and stretch it horizontally using the image width attributes.

Or you can define a single-column table (panelGrid) of the required width and height with a bottom border and nothing in the table. This also works with a straight HTML <div> element.

If you are looking, however, to construct an input form with underlined data entry areas similar to a printed form, you can do a CSS override on the HTML input control to change the box from its default all-around border to one with only a bottom border.
 
Ranch Hand
Posts: 39
Eclipse IDE Chrome Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In style tag include
 
God is a comedian playing for an audience that is afraid to laugh - Voltair. tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/t/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic