This is a discussion on Change Scroller Colour within the Programming Articles forums, part of the Webmaster Articles/Tutorials category; This tut will show you how to let your users choose the scrollbar colour of the browser. Only works in ...
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| | #1 (permalink) |
| Senior Member | This tut will show you how to let your users choose the scrollbar colour of the browser. Only works in IE, Not any others! Simply put this into the <head> of your page. Im using some bright colours, you can choose what you want. Code: //Change colours to what you want where it says "gold" etc.
<style>
body{
scrollbar-3dlight-color:gold;
scrollbar-arrow-color:yellow;
scrollbar-base-color:white;
scrollbar-darkshadow-color:black;
scrollbar-face-color:red;
scrollbar-highlight-color:blue;
scrollbar-shadow-color:green}
}
</style>
//DONT CHANGE ANYY OF THIS BELOW!
<script>
function changeScrollbarColor(C){
if (document.all){
document.body.style.scrollbarBaseColor = C
}
}
</script>
(These are only my colours). Hope you found my first tut helpful. Will be returning with more soon... EDIT: Any problems or comments please post below or PM if your too shy...
__________________ -Gary |
| | |
| | #2 (permalink) |
| Super Moderator | Don't put it in the HTML file, put your script and styles in seperate files, then they can be re-used on every page and cached in the browser making your page load faster.
__________________ Alex Monaghan - Monaghan Consultants Ltd Web hosting, ADSL, IT & Database consultancy Custom Web hosting on UK or USA servers using Linux (cPanel) or Windows (DotNetPanel) Mobile Phone Ringtones, Logos, Java Games & more |
| | |
| | #4 (permalink) |
| Super Moderator | 1 page load time will not make any difference, 2, 3, 4 ... However when you get lots of multiple page views and lots of visitors, then you'll notice a difference. If you're hosting on a cheap server that's heavily loaded, then you want to reduce the volume of data your visitor has to pull down for each page.
__________________ Alex Monaghan - Monaghan Consultants Ltd Web hosting, ADSL, IT & Database consultancy Custom Web hosting on UK or USA servers using Linux (cPanel) or Windows (DotNetPanel) Mobile Phone Ringtones, Logos, Java Games & more |
| | |
| | #6 (permalink) |
| Newbie | Why do you include a javascript? And what is the value of the C that you are passing to the script? It doesn't seem to be defined anywhere. And I'm assuming it is a javascript as it doesn't define the language either. I just use the style settings and it works for me. |
| | |
| | #7 (permalink) |
| Moderator | That is quite a cleaver idea to be honest, it will save loads of hassle of waiting for the page to load.
__________________ Free .org domain - Click for details! Do not pm asking for things. My inbox is full. Add me to MSN! |
| | |
| Tags |
| change, colour, scroller |
| Thread Tools | |
| Display Modes | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| text box colour | Lewis | Website Design Forum | 11 | 27-10-2005 00:09 |
| Can't change logo | Lewis | Graphics Forum | 6 | 17-06-2005 17:19 |
| colour chart | Lewis | General Webmaster Discussion | 2 | 21-05-2005 11:53 |
| Change Scroller Colour | Departed | Comments / Suggestions | 2 | 29-04-2005 16:06 |