Jump to content

problem with div scroll only on right


zuzuu

Recommended Posts

Hello ! I have a problem, I would like to put my text in a div. But if there is a lot of text I want that a scroll appears but only on rigth. I don't want to have a sroll at the bottom of my div. Do you know the property to do this in css div???

Link to comment
Share on other sites

The perfect property you are looking for is this:

div.scrollthing { overflow-y:scroll; overflow-x:hidden; }

When you used this in your page:

...<div class="scrollthing">sometext in here</div>...
Note: you should use linebreaks to have the text between the marges of the div, or else this way would hide the overflowing part.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...