Uutiset:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu
Advertisement:

member info field width

Aloittaja Robert Frost, maaliskuu 09, 2005, 11:38:05 AP

« edellinen - seuraava »

Robert Frost

well, i'm thinking about the part where posts are displayed. The width of the member info field (hope i said correctly) is dictated by:

1) avatar width
2) custom title length

An example:



I would like to make my custom theme appear so smooth and slick as the SMF default theme. So, with everyone wanting to remove the scrollbars, i wish to add them if necessary. Is it possible and how? I hope you catch my drift. I want my forum to look nice, not all messed up with member avatars and all that crap they can pull on me. :)

Sorry if this has been asked before, but i found questions on how to REMOVE avatar scrollbars, not how to ADD them.

Also...members uploaded their avatars. Some of them are wider than 150px, even though i enabled the avatar resizing options (true, i did it after they uploaded them). How to fix that?

rakuli

I can't help with the question but what is that picture? :o

{maybe if you view your page source you can see what class your avatars are and change you style.css to overflow: auto;}?

Robert Frost

thanks for the info, mate, i found it :)

// Show information about the poster of this message.
echo '
<table width="100%" cellpadding="5" cellspacing="0" style="table-layout: fixed;">
<tr>
<td valign="top" width="20%" rowspan="2" style="overflow: auto;">
<b>', $message['member']['link'], '</b>
<div class="smalltext">';


this is the part that defines the width of that column,

// Done with the information about the poster... on to the post itself.
echo '
</span>
</td>
<td valign="top" width="80%" height="100%">
<table width="100%" border="0"><tr>


and this one that defines the second one. In this example, i changed the values to 20% : 80%. Combined it with the default theme's display.template.php, although i still can't get the scrollbars, it hides it all the time! (the avatars)

rakuli

if you want. In this code.
<td valign="top" width="80%" height="100%">

thry this
<td valign="top" style="width:80%; height: ??px; overflow:auto; ">

You need to set the height as a absolute ??=20px value for this to work.
You can set fixed width as well and still just have vertical scrollbars using.

Overflow-y: scroll;


Robert Frost

#4
actually, i figured it out.

replace:
', $message['member']['avatar']['image'], '<br />';

with:
<div style="overflow: auto; width: 100%;">', $message['member']['avatar']['image'], '</div><br />';

but thanks for your info as well :) that overflow-y trick came in well :)

rakuli

you never explained that picture ;D ???

Robert Frost

the thing was this:

IE showed scrollbars on avatars, both horizontal and vertical.


I put a 140px width limit on all avatars, and made the first column a bit wider.

check it out on www.semenka.com/forum

Advertisement: