Hot Mic

Omakase

Amazon Search

Bleg- Calling all coders

So here’s the deal: The “new” WordPress theme I’m using is mostly satisfactory, but when someone places a long bit of “unbreakable” text, like a long URL in the comments box, it shifts the main page area to the left to accomodate the comment length.

Apart from begging commenters to hyper-link to addresses rather than post them in their entirety, does anyone have a clue to wordwrap these long entries around within a fixed-width stylesheet?

(The rest of you may talk amongst yourselves)

Share

7 comments to Bleg- Calling all coders

  • I don’t know about word wrapping them, because I don’t use Word Press, but you could request that they use tiny url to create a small footprint link.

    http://tinyurl.com/

    Or, you could edit the comment and do it yourself if it doesn’t happen too often.

  • I wasn’t able to find a solution on google, and you’re not the only one with this issue.
    I’ve seen other sites beg/demand you use tinyurl.com, which is about as much work as writing link code.

  • Kevin – I prefer tiny url whenever I can’t do a preview so I can test that I typed everything correctly. That’s the only real difference between the two. With tiny url – it’s just copy and paste.

    When creating a link – there are the extra tag characters and my sad inability to type things correctly is my downfall.

  • I’ve used both TinyURL and SnipURL, and nowadays I use SnipURL
    http://snipurl.com/
    Not having used TinyURL for awhile, I can’t remember the difference, but SnipURL couldn’t be easier.

  • Lex,
    That plugin might be your best bet, as there’s not a good way to wrap long words using just CSS. If you really want a CSS solution you can hide the text after it flows off the side of the comment. That’s not really ideal because it’ll make the URL hard to copy, but at least it won’t mess up your layout.

    To do that find this class in your CSS: #content ol.commentlist li and add overflow-x:hidden.

    You could also try to get clever with Javascript to insert breaks in long words, but that’s probably more of a PITA than you want.

    HTH,
    BKR

eXTReMe Tracker

View My Stats