How to split a row (e.g. long URL) in a table cell using CSS?

Here is the situation . I am trying to use my settings on some MySpace settings. If you 've ever tried [stackoverflow], I'm sure you understand how unpleasant it can be.
In principle, all this can be set using CSS, within a certain set of rules (for example, the "#" symbol is not allowed ... how useful it is!).
Look at the blog , if you want more information, I used it as the basis for my settings

So the only problem is with the comment section, where “friends” post whatever they like. He already has ...

max-width:423px; 

... set in the table, but I found that long URLs are placed in the comments section, it gives the width of the table regardless of the maximum setting!

Question : Is there a way to control text that will push the width of the table?
Perhaps splitting / chopping the strings? Or should I do more ...? URLs are sent as text, not hrefs.

Using Firefox and Firebug btw.

Change Also prohibited javascript;)

Other editing Just tested with IE7, and it seems to work .. so firefox is a problem in this case.

+3
css html-table myspace
Sep 26 '08 at 7:23
source share
3 answers

Have you tried different values ​​for the css overflow property? I think this can do what you need in some permutation.

+1
Sep 26 '08 at 7:28
source share

multiple browsers support word-wrap

ex.

 <div style="width: 50px; word-wrap: break-word">insertsuperlongwordhereplease</div> 

Browser support currently is IE / Safari / Firefox 3.1 (Alpha)

+1
Sep 26 '08 at 7:31
source share

Your options are pretty limited if you use only CSS. You can try

  overflow: hidden 

to hide offensive parts. CSS 3 supports text-wrap , but there is probably no support for it. IIRC is an IE-only css property for doing the same, but I can't remember it at the moment, and my Google-Fu doesn't let me.

0
Sep 26 '08 at 7:29
source share



All Articles