PDA

View Full Version : FaceScroll Custom scrollbar



Dzsedzs
10-12-2012, 08:38 PM
1) Script Title: FaceScroll Custom scrollbar

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex11/facescroll/index.htm

3) Describe problem: First let me thank you DD for all the scripts you provide. They are all excellent.

Hello All. What my problem is that I would like to color the Scrollbar in default style. For example I'd like to have it in red. I just couldn't figure it out where I could do that. If someone could help me out I would really appreciate it with a detailed solution where exactly you have to do the changes (which file, where in file).

Thanks in advance, and sorry if already this question has been asked, I just don't have time to see all the threads.


Dzsedzs :)

keyboard
10-12-2012, 10:08 PM
THis is the code you use to call the script (where id is the id of the container to have the scroll bar

$('#id').alternateScroll();
Change it to

$('#id').alternateScroll({ 'vertical-bar-class' : 'vertical-scroll-bar-styled'});
Then, in general.css, add


.vertical-scroll-bar-styled {
background-color:red;
}

Dzsedzs
10-18-2012, 05:59 AM
Thank you, it works. Unfortunately I'd like to use it horizontal not vertical. How do you do that? Thanks in advance.

bernie1227
10-18-2012, 08:00 AM
$('#id').alternateScroll({ 'horizontal-bar-class' : 'horizontal-scroll-bar-styled'});

And:


.horizontal-scroll-bar-styled {
background-color:red;
}