Advertisement:

Not all SMF but has something to do with it)

Aloittaja Robert Frost, helmikuu 28, 2005, 04:16:21 IP

« edellinen - seuraava »

Robert Frost

i have a member whos nick is 24 characters long. Now, on my mainpage, members online are displayed in a table cell. His nick messes up the mainpage :( is there a way to wrap his nick, break it in half, or even (as a last resort) limit nickname lengths in smf (i REALLY wouldn't want to do that)?

look :(


Trekkie101

Erm its not really an emergancy is it?


Also where? I dont see, "DoubleDoubleDouble?" Just change it, im sure it isnt needed like that.

ryanbsoftware

 ::) not what i would conciter an emergency, ust change it, or ask the user to change it.  ;)

Robert Frost


Oldiesmann

Add one of the following to the td tag for that block, depending on what you want to do:

If you want to add a horizontal scrollbar:

style="overflow:auto;"

If you want to just wrap it to the next line:

style="word-wrap:break-word"
Michael Eshom
Christian Metal Fans

Robert Frost

#5
hey, oldiesmann, thanks...will check it out right now.

EDIT: nope, doesn't work...insteading of breaking the word at the end of the cell, it stays in one piece :(

[Unknown]

For overflow: auto; to work, you need an explicit width.  At least, in Internet Explorer you do.

I would personally just use overflow: hidden;.

-[Unknown]

Robert Frost

#7
nope, [Unknown], that one doesn't work either.

EDIT: how do you mean, i need an explicit width?

well, i i tried the overflow:hidden; style and it works. The nickname that is too long is not displayed anymore. Nor is the nickname (instead Hey, nicknamenicknamenicknamenickname, you have x messages, x new says x messages, x new. :) )


not quite the solution i had in mind, but it will have to suffice. Thanks everyone!

Robert Frost

forget all the crap i mentioned earlier.

the thing is this. mozilla firefox is the best piece of browser out there. IE is not.

Firefox makes the nickname go under the next cell. Here is the code:

<span>
<p style="overflow:hidden">
<?php ssi_welcome(); ?></p>
</span>


The same code doesn't work for IE. Even if i add word-wrap:break-word; to the paragraph style.

Is it possible that the style won't work if it isn't in a span tag? cause that's what it did to me.

[Unknown]


Advertisement: