scrollbar color

Everything related to GBook PHP guestbook
Post Reply
Jomar
Posts: 50
Joined: Tue May 22, 2007 8:09 pm

scrollbar color

Post by Jomar »

/*************************************
Title: scrollbar color
Version: 1.6
Author:
Demo:
Download:
Website: http://www.zangkoorts.nl/gbook16/gbook.php

Short description:


*************************************/

I adjusted the color off the scrollbar in style.css, but it only shows in the textfield when you want to write a message.
How do I get it to work in the mainpage of the guestbook?
Henrie
Posts: 1095
Joined: Sun Aug 14, 2005 8:57 pm

Post by Henrie »

Hello Jomar,

Scrollbar color styles are also only shown in Internet Explorer.

Also, if Internet Explorer would follow the w3c-standards correctly it would also not show the scrollbar color in the comments textarea field. The guestbook doctype is xhtml and illegal css-styles (like scrollbar styles) should not be shown at all. Unfortunately Internet Explorer does follow it's own rules.

As a workaround if you would like to show the colored scrollbar you an edit the gbook.php file.
Find lines 1063 and 1064

Code: Select all

echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
and replace it with

Code: Select all

echo '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
This replaces the xhtml doctype with the old html doctype and now Internet Explorer does correctly show it's scrollbar styles.

Greetings,
Henrie
Jomar
Posts: 50
Joined: Tue May 22, 2007 8:09 pm

Post by Jomar »

Tnx, it looks fine now, just how they want it.
chris98
Posts: 7
Joined: Sat Aug 03, 2013 5:32 pm

Re: scrollbar color

Post by chris98 »

Can you PLEASE give me the code which changes the default browser sidebar, I've been looking everywhere for it with little success?
Henrie
Posts: 1095
Joined: Sun Aug 14, 2005 8:57 pm

Re: scrollbar color

Post by Henrie »

Hello Chris98,

I have no idea what you mean by the browser sidebar. This topic is about the scrollbar, or do you mean a part of the scrollbar with it?

Greetings,
Henrie
I do not monitor the Gbook forums regularly anymore since I do not use the Gbook script myself anymore for a long time. But it helped me a lot in learning to understand php.
chris98
Posts: 7
Joined: Sat Aug 03, 2013 5:32 pm

Re: scrollbar color

Post by chris98 »

The scrollbar on every webpage, on the right hand side.In other words, the main one.
Henrie
Posts: 1095
Joined: Sun Aug 14, 2005 8:57 pm

Re: scrollbar color

Post by Henrie »

You could have tried Google?

But here it is

Code: Select all

body{
scrollbar-face-color: #F5F5F5;
scrollbar-face-color: #FFFFFF;
scrollbar-arrow-color: #ABABAB;
scrollbar-track-color: #FFFFFF;
scrollbar-3dlight-color: #ABABAB;
scrollbar-highlight-color: #FFFFFF;
scrollbar-shadow-color: #ABABAB;
scrollbar-darkshadow-color: #FFFFFF;
}
An image with what the different scrollbar parts are, can be found here Image
The blue text is in dutch, translation is:
Scrollbar-track-color
(when for "scrollbar-track-color" you enter the color value "transparent" a checkerboard of the colors "scrollbar-face-color" and "scrollbar-highlight-color" is displayed, ze scrollbar display at the right)
Greetings,
Henrie
I do not monitor the Gbook forums regularly anymore since I do not use the Gbook script myself anymore for a long time. But it helped me a lot in learning to understand php.
chris98
Posts: 7
Joined: Sat Aug 03, 2013 5:32 pm

Re: scrollbar color

Post by chris98 »

I have already tried with Google, but I get the textarea scroll bar things instead.

You are just supposed to integrate it with the CSS, aren't you because in mine it did nothing?


Oh...wait.Could it be my browser that is stopping me from seeing it?
Henrie
Posts: 1095
Joined: Sun Aug 14, 2005 8:57 pm

Re: scrollbar color

Post by Henrie »

This has to be done in the css of the page.

And as written before in this thread it is only supported in Internet Explorer (in the past, I do not know if they still support it because it is not a css standard property).

My advice would be to not try to change the scrollbar colors.

Greetings,
Henrie
I do not monitor the Gbook forums regularly anymore since I do not use the Gbook script myself anymore for a long time. But it helped me a lot in learning to understand php.
Post Reply