wood burning stoves 2.0*
The moose likes HTML, CSS and JavaScript and the fly likes Text  wraps underneath radio buttons Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Text  wraps underneath radio buttons" Watch "Text  wraps underneath radio buttons" New topic
Author

Text wraps underneath radio buttons

Jesse Torres
Ranch Hand

Joined: Mar 25, 2004
Posts: 985
Hello to all,


Some of my forms have radio buttons with long labels. When the text is too long, it wraps underneath the button, which looks terrible, instead of just under the text.

Example - What it looks like:
- aaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaa
- bbbbbbbbbbbbbbbbbbbbbbbbbb
bbbbbbbbbbbbbbbbbbbbbbbbbbbb

I want to have the second line of text under the first line of text.

Please help.

Thanks,
[ June 15, 2006: Message edited by: Jesse Torres ]

-- <br />4 8 15 16 23 42
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
place it in a div and float the div or use multiple cells

Eric
Jesse Torres
Ranch Hand

Joined: Mar 25, 2004
Posts: 985
Originally posted by Eric Pascarello:
place it in a div and float the div or use multiple cells

Eric


Hello Eric,

Thank you so much for your help. The float tag perfectly aligned the second line of text under the first one. However, now this is the output:

Now both lines wrap under the radio button.
-
aaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaa
-
bbbbbbbbbbbbbbbbbbbbbbbbbb
bbbbbbbbbbbbbbbbbbbbbbbbbbbb



Please help.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60758
    
  65

Don't float the label, just the radio button.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Jesse Torres
Ranch Hand

Joined: Mar 25, 2004
Posts: 985
Originally posted by Bear Bibeault:
Don't float the label, just the radio button.


Hello,

Thanks!!!

I have floated the radio button and it works fine. However, it only works in IE. It doesn't work in Firefox. So now I am trying to get it to work on Firefox.

Thanks again
Jesse Torres
Ranch Hand

Joined: Mar 25, 2004
Posts: 985
Help!

This is working fine for IE. However, it is not with Firefox. It works on certain lines with Firefox while it doesn't work on others.
Example - What it looks like with Firefox.
- aaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaa
- bbbbbbbbbbbbbbbbbbbbbbbbbb
bbbbbbbbbbbbbbbbbbbbbbbbbbbb

Help

Thanks,

sus
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
Why don't you show us what you are doing!

Eric
Jesse Torres
Ranch Hand

Joined: Mar 25, 2004
Posts: 985
Originally posted by Eric Pascarello:
Why don't you show us what you are doing!

Eric


Hello,

I am using an IDE that basically creates the HTML. However, I can still manipulate the templates (that give me access to CSS settings). This is the only way that I can control HTML code. I cannot modify HTML output. I can only do it through templates.

CSS
mrSingleText is the label text
mrSingle is the radio button.

<!-- .mrSingleText {font-family:arial; font-size:11pt;}-->
<!-- .mrSingle {float: left;}-->

Thanks,
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60758
    
  65

Originally posted by Jesse Torres:

This is the only way that I can control HTML code. I cannot modify HTML output.


And you are using this productivity prevention tool because... ?
Jesse Torres
Ranch Hand

Joined: Mar 25, 2004
Posts: 985
We use the tool at work. I don't have a "say-so" on this.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60758
    
  65

My sympathies. Tools are supposed to help, not hinder you.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: Text wraps underneath radio buttons
 
Similar Threads
How to disable text box dynamically ?
how to disable text input field and change color or text box?
How can I disable a text input field?
Focusing Radio Button
Displaying an outputLabel below a radio button