Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Is it possible to have the firefox browser (or chrome) use font overrides on particular web pages?

To be specific, I'm trying to look for a way to make all the wikipedia pages display in sans-serif instead of sans.

share|improve this question
add comment

3 Answers

up vote 7 down vote accepted

If you want to override the fonts in Wikipedia specifically, edit Special:MyPage/vector.css (for the default Vector skin):

Example:

#bodyContent {
    font-family: serif;
}

This is stored in your Wikipedia account and works for all browsers. If you are using a different skin (theme), change the .css name (e.g. monobook.css).

(I assume you meant to write "display in serif instead of sans", because "sans" and "sans-serif" are the same thing.)

Example for a specific font: font-family: Garamond, "Times New Roman", serif;


For a more general solution, install the Stylish extension for Firefox or Chrome. (In Firefox, you can manually edit userContent.css.) This way you can set overrides for specific sites, or for everything.

Example for Wikipedia:

@namespace url(http://www.w3.org/1999/xhtml);
@-moz-document url-prefix(http://en.wikipedia.org/) {
    #bodyContent {
        font-family: serif;
    }
}

It's mostly the same as above, but with added @namespace, and wrapped inside an @-moz-document block.

share|improve this answer
1  
Stylish (well, at least on Firefox, can't comment on Chrome but I'd assume so) can be used on a site-by-site bases as well as universally. –  DMA57361 May 6 '11 at 12:10
    
That's just awesome. –  Blomkvist May 6 '11 at 12:18
    
Thanks. And yes, serif, not sans serif. –  morgoth_bauglir May 7 '11 at 7:36
add comment

You can creat an account with Wikipedia and and upload your own css or select from a given list , some of which have san-serif fonts as default (myskin,nostalgia,simple,standard)

share|improve this answer
add comment

See grawity's answer. Otherwise,

In firefox got to tools>options>content>font>advanced settings and disallow websites to choose their own fonts.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.