Speakeasy forum

General discussion

Style sheet for Firefox

by C1ay / November 11, 2006 10:08 AM PST

Some members here may find this useful. Firefox allows you to use your own style sheet to control the apperance of websites in the browser. It also allows you to do so on a site-specific basis so that you can change font sizes and colors, backgrounds and other stuff to your preferences for any particular site without effecting any others. This is done by creating a userContent.css file in the chrome directory of your profile.

I've created a section in mine for the forums here. It changes all the unvisited forum links to black and the visited link to a dark shade of gray. I've set my fonts to size 14px, changed green boxes to light gray. For my old eyes it helps so maybe so of you will find it useful. Here's a copy of my forums style sheet:

/********Begin CNet Forums Styles*******************/

@-moz-document url-prefix(http://forums.cnet.com/) {
#forum-threads a:link, a:hover {color:#000 ! important;}
#forum-threads a:visited {color:#666 ! important;}
#forum-threads span.by {color:#666 ! important;font:normal 12px arial,helvetica ! important;}
#forum-threads th {background:#f3f3f3 ! important;height:30px;text-align:left;font:bold 11px verdana,helvetica;}
#forum-threads td.t {width:369px;padding-right:20px;font:normal 14px arial,helvetica ! important;}
#forums06 .by {color:#666 ! important;font:normal 12px verdana,helvetica ! important;margin-bottom:20px;}
#forums06 a:link, a:visited, a:hover {color:#000 ! important;font:normal 14px arial,helvetica ! important}

#forums06 #posts .post-l0 {border:solid 1px #666 ! important;width:788px;margin:10px 0 0 0px;}
#forums06 #posts .post-l1 {border:solid 1px #666 ! important;width:773px;margin:10px 0 0 15px;}
#forums06 #posts .post-l2 {border:solid 1px #666 ! important;width:758px;margin:10px 0 0 30px;}
#forums06 #posts .post-l3 {border:solid 1px #666 ! important;width:743px;margin:10px 0 0 45px;}
#forums06 #posts .post-l4 {border:solid 1px #666 ! important;width:728px;margin:10px 0 0 60px;}
#forums06 #posts .post-l5 {border:solid 1px #666 ! important;width:713px;margin:10px 0 0 75px;}
#forums06 #posts .post-l6 {border:solid 1px #666 ! important;width:698px;margin:10px 0 0 90px;}
#forums06 #posts .post-l7 {border:solid 1px #666 ! important;width:683px;margin:10px 0 0 105px;}
#forums06 #posts .post-l8 {border:solid 1px #666 ! important;width:668px;margin:10px 0 0 120px;}
#forums06 #posts .post-l9 {border:solid 1px #666 ! important;width:653px;margin:10px 0 0 135px;}
#forums06 #posts .post-l10 {border:solid 1px #666 ! important;width:638px;margin:10px 0 0 150px;}
#forums06 #posts .post-l11 {border:solid 1px #666 ! important;width:623px;margin:10px 0 0 165px;}
#forums06 #posts .post-l12 {border:solid 1px #666 ! important;width:608px;margin:10px 0 0 180px;}

#forums06 #posts .post-l0-active {border:solid 1px #666 ! important;width:780px;margin:10px 0 0 0px;}
#forums06 #posts .post-l1-active {border:solid 1px #666 ! important;width:765px;margin:10px 0 0 15px;}
#forums06 #posts .post-l2-active {border:solid 1px #666 ! important;width:750px;margin:10px 0 0 30px;}
#forums06 #posts .post-l3-active {border:solid 1px #666 ! important;width:735px;margin:10px 0 0 45px;}
#forums06 #posts .post-l4-active {border:solid 1px #666 ! important;width:720px;margin:10px 0 0 60px;}
#forums06 #posts .post-l5-active {border:solid 1px #666 ! important;width:705px;margin:10px 0 0 75px;}
#forums06 #posts .post-l6-active {border:solid 1px #666 ! important;width:690px;margin:10px 0 0 90px;}
#forums06 #posts .post-l7-active {border:solid 1px #666 ! important;width:675px;margin:10px 0 0 105px;}
#forums06 #posts .post-l8-active {border:solid 1px #666 ! important;width:660px;margin:10px 0 0 120px;}
#forums06 #posts .post-l9-active {border:solid 1px #666 ! important;width:645px;margin:10px 0 0 135px;}
#forums06 #posts .post-l10-active {border:solid 1px #666 ! important;width:630px;margin:10px 0 0 150px;}
#forums06 #posts .post-l11-active {border:solid 1px #666 ! important;width:615px;margin:10px 0 0 165px;}
#forums06 #posts .post-l12-active {border:solid 1px #666 ! important;width:600px;margin:10px 0 0 180px;}

#forum-w .grn-bx {background:#f3f3f3 ! important;}
#forums06 p {font:normal 14px arial,helvetica ! important;margin-bottom:15px;color:#333;}
#forums06 .grn-dots {background: #fff ! important;margin:0 10px 30px 10px;}
#forums06 .prev-post {background:#fff ! important;border:solid 1px #333 ! important;width:778px;*width:788px;padding:0 0 0 10px;}
#forums06 .prev-post-reply {background:#fff url('http://i.i.com.com/cnwk.1d/i/arrow-blk.gif') no-repeat ! important; background-position:15px 14px;border:solid 1px #fff ! important;width:768px;padding:0 0 0 20px;}
#forum-w .f_current {background:#f3f3f3 ! important;}
#forum-w .active-thread {padding:0 0 0px 0;background:#f3f3f3 ! important;}

/****************End Cnet Forums Styles*********************/

If you use this or make changes to it you must restart your browser to see the changes.

Perhaps someone will find this useful,

Discussion is locked
You are posting a reply to: Style sheet for Firefox
The posting of advertisements, profanity, or personal attacks is prohibited. Please refer to our CNET Forums policies for details. All submitted content is subject to our Terms of Use.
Track this discussion and email me when there are updates

If you're asking for technical help, please be sure to include all your system info, including operating system, model number, and any other specifics related to the problem. Also please exercise your best judgment when posting in the forums--revealing personal information such as your e-mail address, telephone number, and address is not recommended.

You are reporting the following post: Style sheet for Firefox
This post has been flagged and will be reviewed by our staff. Thank you for helping us maintain CNET's great community.
Sorry, there was a problem flagging this post. Please try again now or at a later time.
If you believe this post is offensive or violates the CNET Forums' Usage policies, you can report it below (this will not automatically remove the post). Once reported, our moderators will be notified and the post will be reviewed.
Collapse -
Probably should head over to a Windows forum ...
by Evie / November 11, 2006 11:12 PM PST

... but I have XP and simply cannot find my profiles folder! It's supposed to be under C:\Documents and Settings, but I see nothing there for my login name!

Evie Happy

Collapse -
It should be at
by C1ay / November 11, 2006 11:39 PM PST

c:\documents and settings\your_user_name\application data\Mozilla\Firefox\Profiles\xxxxxxxx.default\chrome\ where xxxxxxxx is a random string of 8 characters....

Collapse -
It should be ...
by Evie / November 11, 2006 11:43 PM PST
In reply to: It should be at

... but I don't see a folder for my user name in Documents and Settings!! Is it possible that is hidden?

Evie Happy

Collapse -
by C1ay / November 11, 2006 11:51 PM PST
In reply to: It should be ...

it shouldn't be. Sometimes the Application Data folder is hidden but your user folder should be there. Try searching your hard drive for "chrome". It should come up at least twice, once in the Firefox installation folder and once in your profile, and search will show the full path to each occurence. Maybe that will help locate your user folder for windows.

Collapse -
Run a Search
by James Denison / November 11, 2006 11:52 PM PST
In reply to: It should be ...

.....for any folders with Mozilla or Profile in their name.

Collapse -
Didn't work :(
by Evie / November 12, 2006 6:46 AM PST
In reply to: Run a Search

This is very strange, but don't have the time to tackle it with focus today.

Collapse -
Worked for med....
by EdH / November 12, 2006 8:26 AM PST
In reply to: Didn't work :(

I'll try it for a while. Might try some modifications (and probably break it).

Collapse -
I meant the search
by Evie / November 12, 2006 8:28 AM PST
In reply to: Worked for med....

I have no such directory, or, apparently, any profile of my username anywhere on this computer?!!

This machine is clean, clean, clean. No viruses EVER. No spyware. NADA. I find this strange. But I'm checking in between watching various TV with the hubby today so am not in a position to devote time to focus on what's up.

Evie Happy

Collapse -
Try searching for mozilla
by C1ay / November 12, 2006 8:34 AM PST
In reply to: Didn't work :(

You've certainly got a mozilla folder somewhere if Firefox is installed.

Collapse -
When I do that ...
by Evie / November 12, 2006 9:14 AM PST

... the only user profile I get is for the old computer stuff I copied over to this new(er) one.

I have my computer set up for two users. I log in to my user every time I restart this computer. That may not be every day, but it is not infrequent.

The only apparent current stuff for Mozilla on this computer is under "All Users" and there is no profile, application data or anything of the sort I used to have. I've never had reason to check for this until now. How VERY odd!

Evie Happy

Collapse -
In Wondows Explorer
by C1ay / November 12, 2006 9:19 AM PST
In reply to: When I do that ...

Go to Tools>>Folder Option>>View and check the radio button for "Show hidden files and folders" Win2K shows these in a search, even if they're hidden, but XP may not.

Collapse -
Did that ...
by Evie / November 12, 2006 9:51 AM PST
In reply to: In Wondows Explorer

... and now I see some previously hidden "Application Data" folders, etc. STILL Sad Nothing for my profile! Or Mozilla for my profile ... or for any other profiles for that matter (no Admin or Owner ... NADA :(!!)

Evie Happy

Collapse -
Well then....
by C1ay / November 12, 2006 10:18 AM PST
In reply to: Did that ...

Maybe your installation of Firefox is using a profile stored somewhere else. I'm not sure why you don't have a profile folder for your user under Documents and settings but maybe we can find out where your installation of Firefox is storing your settings. Try this. While in Firefox make a fresh bookmark of any web page. Next, do an immediate search for bookmarks.html. There should or could be a few of them but you will be interested in the one with the last timestamp on it. In whatever folder that bookmarks.html file is in should also be a folder named chrome that your current instance of Firefox is looking at for settings.

Collapse -
Nothing :(
by Evie / November 12, 2006 11:01 AM PST
In reply to: Well then....

Only thing that comes up in search is old bookmarks from my Toshiba :(:(

Evie Happy

Collapse -
by C1ay / November 12, 2006 11:16 AM PST
In reply to: Nothing :(

That is odd since you should at least have the default bookmarks in the Firefox program folder, usually at C:\Program Files\Mozilla Firefox\defaults\profile\bookmarks.html Maybe someone in the XP forum has an idea...

Collapse -
Try this...
by John.Wilkinson / November 12, 2006 11:33 AM PST
In reply to: Nothing :(

The Firefox profile location can be changed, but a search for the folder and the bookmarks.html file should have found it. Regardless, though, click here and download the extension ChromEdit Plus. Once installed restart Firefox and then go Tools->ChromEdit Plus->Chrome Folder. That should launch Windows Explorer and take you right to the folder you're looking for. You can then open up userContent-example.css, replace the content with Clay's code, save the file, and then rename the file to remove the -example bit.

Hope this helps,

P.S. Now, can someone point me the way out of here before someone starts shooting at me? Wink

Collapse -
Are you sure you're using Firefox?
by James Denison / November 12, 2006 1:57 PM PST
In reply to: Nothing :(

If you just switched over, you may have imported all those settings into
IE and using it thinking you are on Firefox.

Collapse -
One other way to try ...
by Bill Osler / November 12, 2006 8:35 PM PST
In reply to: Nothing :(

Try opening an explorer window and putting %Appdata% into the address bar. The FF stuff should be in an arbitrarily named directory under %Appdata%\Mozilla\Firefox\Profiles

Collapse -
Thanks to all
by Evie / November 12, 2006 8:42 PM PST
In reply to: Nothing :(

I finally found it. Odd that my username is nowhere to be found on this computer, but it's what I log on as all the time?! I also perhaps didn't refresh my view to show the hidden files last time poking through the subdirectory I finally found it at. Why these files should be hidden is beyond me Sad They never were before, and I didn't do anything to actively hide them :(:(

Now to get it to see the style sheet.

Thanks again Happy

Evie Happy

Collapse -
You may have tried this already ...
by Bill Osler / November 12, 2006 8:55 AM PST
Firefox Help: Editing Configuration Files

Locate your profile folder

Before the configuration files are presented, you should know how to find your profile folder, which is where Firefox saves all your settings on your hard drive.

* On Windows XP/2000, the path is usually %AppData%\Mozilla\Firefox\Profiles\xxxxxxxx.default\, where xxxxxxxx is a random string of 8 characters. Just browse to C:\Documents and Settings\[User Name]\Application Data\Mozilla\Firefox\Profiles\ and the rest should be obvious.
* On Windows 95/98/Me, the path is usually C:\WINDOWS\Application Data\Mozilla\Firefox\Profiles\xxxxxxxx.default\
* On Linux, the path is usually ~/.mozilla/firefox/xxxxxxxx.default/
* On Mac OS X, the path is usually ~/Library/Application Support/Firefox/Profiles/xxxxxxxx.default/

%AppData% is a shorthand for the Application Data path on Windows 2000/XP. To use it, click Start > Run..., enter %AppData% and press Enter. You will be taken to the "real" folder, which is normally C:\Documents and Settings\[User Name]\Application Data.

Firefox is capable of handling more than one user and thus, more than one profile. The path examples above refers to the default profile that is automatically created when you start Firefox for the first time. You can manage any number of profiles by using the Profile Manager.

At least one of the sites I found said that the files are hidden by default. My understanding is that the Application Data folder in XP is also hidden by default (it's a sub-folder in your user profile). I have Windows Explorer set to display hidden files and folders so I have never really paid attention to whether the files/folders are hidden.

I'm out of my depth here, but IIRC it is possible in XP for your user data to be someplace other than \Documents and Settings\username\... but it would take a deliberate effort to accomplish that.
Collapse -
I think you hit on it
by James Denison / November 12, 2006 8:59 AM PST

Those not finding the mozilla folder probably haven't set their file explorer
to show all hidden and system files.

Collapse -
I officially hate XP ;-)
by Evie / November 12, 2006 9:27 AM PST
In reply to: I think you hit on it

I have found some Application Data folders now that I've changed that which I never hid Sad Still doesn't show my username which I find VERY disturbing. Will play with this tomorrow when I can devote uninterupted time to this.

Collapse -
Like I just replied to Clay ...
by Evie / November 12, 2006 9:18 AM PST

... I haven't had reason to even delve into this. My userID is not even recognized on my computer! Sad I never did anything deliberate to accomplish that! :(:(

Evie Happy

Collapse -
So do I need to learn how to use CSS now?
by EdH / November 11, 2006 11:17 PM PST

Been putting that off...

Collapse -
by C1ay / November 11, 2006 11:42 PM PST

There are a lot of HTML tags like font that are being deprecated by style sheets.....

Collapse -
Hi Clay...
by Rolway / November 12, 2006 12:10 AM PST
In reply to: Yeah

I'm there, but all I have is the envelope "Chrome" with (2) "user Chrome-example.css, cascading style sheet documents. One sized 1.05kb, the other 663 bytes."......No string of numbers you described.

I imagine I copy and paste your style sheet in there. But which one? I'm using FF2

George., thanks

Collapse -
That's it
by C1ay / November 12, 2006 12:16 AM PST
In reply to: Hi Clay...

You can rename the one call userContent-example.css or just create a new text file there and name it userContent.css. Then copy and paste from my post and save it. The example file you see also has some examples you could use to alter all sites that you visit like turning off blink and marquee tags.

Collapse -
(NT) Got It. Thanks Clay...Will give it a try...
by Rolway / November 12, 2006 1:20 AM PST
In reply to: That's it
Collapse -
Hate to look stupid here Clay...
by Rolway / November 12, 2006 2:23 AM PST
In reply to: That's it

but now that you got my attention, how do I access this to make the changes. I have it installed in chrome and re-booted FF. Unable to find the launching site.

George Sad

Collapse -
There's nothing to launch
by C1ay / November 12, 2006 2:29 AM PST

Once you save the style sheet in your profile, your browser shou;d use it when you visit the forums. If you want to make changes to it you can open it in a text editor.

Popular Forums
Computer Newbies 10,686 discussions
Computer Help 54,365 discussions
Laptops 21,181 discussions
Networking & Wireless 16,313 discussions
Phones 17,137 discussions
Security 31,287 discussions
TVs & Home Theaters 22,101 discussions
Windows 7 8,164 discussions
Windows 10 2,657 discussions


Your favorite shows are back!

Don’t miss your dramas, sitcoms and reality shows. Find out when and where they’re airing!