Sign Up! Login: Password: New User? Forgot? Support
Code 
 
 
Forums 
Forums : News > News Box Scrolling
Mottie (SuperAdmin) 1/1/2011 4:58 AM EST : News Box Scrolling
ACK!
Mottie
Posts: 3884

0
Like

0
Dislike

News Box Scrolling

GuildPortal admin site link to the original post

This bit of CSS sets the height of your news box widget and makes the content scrollable - just as you see it on my Help Site Home page.

Add the following css to your custom css (Control Panel > Custom HTML & Script > Custom CSS > CSS Addtions to Standard)
.gpWidget-newslrg .blkContent {
 height: 350px;
 overflow-y: auto;
 overflow-x: hidden; /* this line may not be necessary, unless a horizontal scroll bar appears */
 padding-right: 5px;
}
Adjust the new box height (in red) as desired.

If the css above doesn't work as is for your site, then add this bit of scripting to your custom javascript (Control Panel > Custom HTML & Script > Custom Javascript/JQuery > Document Ready Event tab)
$('.gpWidget-newslrg').find('.blkContent').wrapInner('<div class="blkContent"/>');

Edit (1/29/2011): Added script to make the css work with all themes.
Characters: Mottie Motty Mortie Ooshiny Mot Fudgems
TopBottom

Lansgirl (Applicant) 1/29/2011 7:26 AM EST : RE: News Box Scrolling
Lansgirl
Posts: 47

0
Like

0
Dislike

hey Mottie , could this be adapted to make any of the content boxes scrollable? For instance my home page is growing longer and longer with "boss kill screenshots" so I would like to turn that content box into a set height so the first image is viewable and then you can scroll down to see the rest.
TopBottom

shadowstts (Member) 1/29/2011 8:03 AM EST : RE: News Box Scrolling
shadowstts
Posts: 364

0
Like

0
Dislike

i agree with lands girl that woudl be a nice idea also the script isnt work for my site really would liek it guild downing alot bosses 

Asylum RULES!

TopBottom

Mottie (SuperAdmin) 1/29/2011 6:13 PM EST : RE: News Box Scrolling
ACK!
Mottie
Posts: 3884

0
Like

0
Dislike

Hi Lansgirl & Shadowstts!

I just posted some code that will allow you to make any widget scrollable, tell me if you have any problems with it 

Characters: Mottie Motty Mortie Ooshiny Mot Fudgems
TopBottom

 
 
Key 
New posts No new posts
New posts ( popular ) No new posts ( popular )
New posts ( sticky ) No new posts ( sticky )
New posts ( locked ) No new posts ( locked )
 
 
Who's Online 
There are   members online.
 
 
So-and-so has logged on!
%title%
%message%