TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,966
  • Latest: safir45
Stats
  • Total Posts: 195,982
  • Total Topics: 21,320
  • Online today: 307
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 0
  • Guests: 203
  • Total: 203

Help needed.. how do i add a scrollbar to the users online in the stats block ?

Started by knat, December 04, 2006, 05:08:56 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

knat

Help needed.. how do i add a scrollbar to the users online in the stats block ?  :o

Just like it has here on this forum..  :)

IchBin

It automatically adds a scroll bar once there are so many users in the list.

knat

Quote from: IchBinâ„¢ on December 04, 2006, 06:14:25 PM
It automatically adds a scroll bar once there are so many users in the list.

Thanks ichbin. Is there any way to change this number ? I had 12 people online today and it really messed up my layout pushing the other blocks downwards ! i would love to make the scrollbar appear at around 8 users online.

IchBin

If you open the default/TPortalBlocks.template.php and look for this line you can change it.
<div style="width: 100%; ' , $online['num_users']>14 ? 'height: 23ex;overflow: auto;' : '' ,'">';

knat

Im amazed i didn't see that little bit of code myself LoL been looking at that file 20 times now..  ::)

Thanks alot for helping me out..  :)  :)  :)

knat

Is it possible to make the users online list a constant height.. and then show scrollbar if the height is exceded ?

Ã,´so the box dont push the box below it up and down depending on how many are online..

I hope i make myself clear in explaining what i am looking for.

I know that it is this line i need to change.. but how ??

I want it to show a scrollbar if more than five online.. but i want it to be like 100 px in height.. even if there is only two online !!

Edit: I try this but it dont work  :P

2nd Edit: Never mind i figured it out   :D

<div style="width: 100%; ' , $online['num_users']>1 ? 'height: 22ex;overflow: auto;' : '' ,'">';

<div style="height: 200 px;  width: 100%; ' , $online['num_users']>5 ? 'height: 23ex;overflow:

What is 'height: 23ex; ??

This website is proudly hosted on Crocweb Cloud Website Hosting.