Only IE officially has a style that explicitly sets the wrapping of content to allow breaking words. So, at least for that browser (Safari 3 Win also respects this style), you could set:
Code:
.balloonstyle, .balloonstyle * {
word-wrap: break-word;
}
Now, all browsers will break a URL on the up slashes (/). So it may not be quite as bad as you think.
Another choice would be to validate the length of the URL segments, and either not allowing:
if that's what you really meant, or adding <br> tags every 10 (or whatever) characters if what you meant was 'long'.
If you put <wbr></wbr> tags around each character, it will allow it to wrap on any character in FF, Safari 3 Win, and IE, but not Opera:
HTML Code:
<wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr><wbr>g</wbr>
Any of these ideas (with the exception of the style) would require an addition to the code you use to dynamically generate the tip content. To help there, if you need/want it, it would be best to see your code that does that.
One style that just about all browsers would respect is overflow. You could set the overflow to hidden, this would crop the extra portion, make it invisible.
Bookmarks