Domanda

I am having a long drop down menu .I have used the overflow property by which it is getting scrolled....But it does not look nice...Please suggest me how to give good CSS to scrollbars

È stato utile?

Soluzione

In modern browsers you can only use proprietary css properties to style the scroll bar. Here is a link to the -webkit properties available: http://css-tricks.com/custom-scrollbars-in-webkit/

If you want a more cross-browser solution, you're going to have to use some JS. Here's a plugin that I've used before that works fairly well and is easily customizable: http://www.dynamicdrive.com/dynamicindex11/facescroll/index.htm It works like the scroll bars on Facebook and works extremely well for dropdown menu scenarios.

Altri suggerimenti

Try to use jScrollPane (jquery plugin) instead a default browser scrollbar.

Example: http://www.kelvinluck.com/assets/jquery/jScrollPane/examples.html

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top