Is there a way to force huge urls such as http://www.google.de/search?q=65daysofstatic&hl=de&safe=off&prmd=ivnsl&source=lnms&tbm=isch&ei=P9NkToCRMorHsgaunaClCg&sa=X&oi=mode_link&ct=mode&cd=2&ved=0CBkQ_AUoAQ&biw=1697&bih=882
break when rendered in the website? I'd rather shorten it but where I'm working they've asked me to show the entire url but I only have a space of 320px to show it and it overflows.
Overflow:hidden, isn't an option either and adding a style to the td where the url is contained is simply ignored.
The Chicago Manual of Style recommends breaking long URLs (see fig. 1): After a colon or a double slash (//) Before a single slash (/), a tilde (~), a period, a comma, a hyphen, and underline (_), a question mark, a number sign, or a percent symbol.
The <br> HTML element produces a line break in text (carriage-return).
overflow-wrap to the rescue:
Note: In contrast to word-break, overflow-wrap will only create a break if an entire word cannot be placed on its own line without overflowing.
it has pretty much full browser support and will help when your long word (E.G URLs) cannot fit in the available space
https://developer.mozilla.org/en-US/docs/Web/CSS/overflow-wrap
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With