Link to home
Start Free TrialLog in
Avatar of roscoeh23
roscoeh23

asked on

Word Break and PHP

If you look at the two news articles at the top here. The one on the right has problems as there is no word break. This leaves a big gap. Is there a way to break the word with php?


http://vps.aztechost.co.uk/~trisco/
ASKER CERTIFIED SOLUTION
Avatar of hernst42
hernst42
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
You can also do this in CSS by applying the attribute - word-wrap: break-word - you can add it to the body tag for it to apply across the whole document. I believe that the element (or it's parent) needs to have a width set for the word-wrap attribute to work.

Remember - Style should be controlled by style sheets. ;)

DM.
Avatar of roscoeh23
roscoeh23

ASKER

None of these methodes work as the problem is the hyperlink. Britishtriathlon.org.

Any ideas?

Ta.
No but breaking links over several line is in my opinion no good idea. You can try to add spaces after the. or just use the domain without the www in front of. Or use other text like homepage of XX which will break correctly.