...

View Full Version : Scroll bar



quartzy
02-13-2011, 02:08 AM
I have searched the internet and cannot find code for a simple news box, so the best way is to make my own newsbox with a scroll bar to move downwards on the div.

How would I do this?

teedoff
02-13-2011, 02:27 AM
I think dynamicdrive.com has some you might can use. If I'm thinking of the right thing you're wanting.

quartzy
02-13-2011, 02:32 PM
No dynamic drive does not have anything I want.
I just want a small div with a scrollbar on it. Do I add overflow: scroll-y?

VIPStephan
02-13-2011, 02:46 PM
overflow: auto would be the current standards compliant way to do it. overflow-x and -y are Microsoft proprietary properties that are going to be in the upcoming CSS3 recommendation, though. But test browser support before considering to use it.

By the way: http://www.brunildo.org/test/Overflowxy2.html

quartzy
02-13-2011, 03:00 PM
Thanks for the link stephen, I checked at wc3 schools and am sorted now, with the link you gave.

quartzy
02-13-2011, 03:25 PM
I tried it with browsers FF3 and IE8 but I dont have a scrollbar.


div#info {
width: 260px;
height: 100px;
overflow:auto;
padding: 0.50em;
margin: 0;
float:right;}

p.ticker {
width: 240px;
border-bottom: 1px dashed #ccc;
padding-bottom: 1em;
margin: 0; padding-top: 5px;}


the html is:

<div id="info">
<h4 class="booking_box">Latest News!</h4>
<p class="ticker">
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec suscipit, ante id porttitor faucibus, odio eros pellentesque sapien, at consectetur mi nibh at massa.</p>
<p class="ticker">orem ipsum dolor sit amet, consectetur adipiscing elit. Donec suscipit, ante id porttitor faucibus, eros pellentesque sapien, at consectetur mi nibh at massa.</p>
</div>



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum