olav78 Posted December 27, 2006 Share Posted December 27, 2006 Hello!I'm wondering how I can set buttons where the text continues to the next «line» of the button if it is longer than the size of the button.In FF this works (the button get twice as high and the text spans two lines): div#local button { width: 100%;} IE, however, cuts the text and the last bit is not showed...? Anyone know how I can get this to work in IE? Link to comment Share on other sites More sharing options...
vchris Posted December 27, 2006 Share Posted December 27, 2006 How about doing this: div#local button { width: 200px; height: 100px; } Make sure the width is perfect so the text is on 2 lines and the height is just in case the height is not good enough by default. Link to comment Share on other sites More sharing options...
olav78 Posted December 27, 2006 Author Share Posted December 27, 2006 nope. stupid IE still just shows one line of text. Hmmm, I beginning to belive that it's impossible to have two lines buttons in IE. Link to comment Share on other sites More sharing options...
PrateekSaxena Posted December 27, 2006 Share Posted December 27, 2006 Isnt there a wordrap option for the CSS of DIVs?? Link to comment Share on other sites More sharing options...
vchris Posted December 27, 2006 Share Posted December 27, 2006 This should help you.http://www.w3.org/TR/css3-text/#wrapping5.2. Force Wrapping: the 'word-wrap' property Link to comment Share on other sites More sharing options...
olav78 Posted December 27, 2006 Author Share Posted December 27, 2006 thanks! but it still does not work in IE...here is the CSS-element: div#local button { width: 100%; word-wrap: break-word; text-wrap: unrestricted;} Link to comment Share on other sites More sharing options...
vchris Posted December 27, 2006 Share Posted December 27, 2006 show me your input button.I tried to do it and it doesn't work in both FF and IE. Your id should not be 2 words. Try renaming it to local_button. Link to comment Share on other sites More sharing options...
olav78 Posted December 28, 2006 Author Share Posted December 28, 2006 Your id should not be 2 words. Try renaming it to local_button.it's not two words, i define the div with id=local another place (its a div for a local menu). "div#local button" means all the buttons inside the div with id=local... Link to comment Share on other sites More sharing options...
PrateekSaxena Posted December 28, 2006 Share Posted December 28, 2006 Ah! Yes this is the wordrap that I was talking about! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now