• Resolved andreasdk

    (@andreasdk)


    I have installed Google Fonts on my site and used it to change the font of h1, which states the name of my blog.

    But when I clich a blog post to read it on single.php the h1 changes to default.

    Can someone help me sort this out?

Viewing 10 replies - 1 through 10 (of 10 total)
  • Change:

    h1 {
        font-family: 'Bentham', arial, serif;
    }

    to:

    h1,
    #header #title {
        font-family: 'Bentham', arial, serif;
    }
    Thread Starter andreasdk

    (@andreasdk)

    Which file is that in?

    I cannot find it in single.php, which i suspect to be where the mistake is.

    single.php

    I have installed Google Fonts on my site

    – where did you add the google web font styles?

    It looks like it’s in your theme’s header.php or possibly in functions.php.

    Thread Starter andreasdk

    (@andreasdk)

    I just added them through the Add plug in menu.

    The code is neither in functions.php, header.php or single.php.

    I’d try adding this code to the bottom of your theme’s style.css file:

    #header #title {
        font-family: 'Bentham', arial, serif;
    }

    Thread Starter andreasdk

    (@andreasdk)

    Unfortunately, that did not help.

    I looked at your theme’s style.css file and did not see the added style code. Regardless, I also saw which plugin you were using. There should be a Custom CSS textarea for the “Bentham” font.

    Add this to the custom CSS textarea and save:

    #header #title {
        font-family: 'Bentham', arial, serif;
    }

    Thread Starter andreasdk

    (@andreasdk)

    Is this what you mean? (in google-fonts.php)

    <p><strong>Custom CSS:*</strong></p>
    <textarea name="googlefont1_css" cols="70" rows="8" id="googlefont1_css">
    <?php echo stripslashes($this->options['googlefont1_css']) ; ?>
    #header #title {
       font-family: 'Bentham', arial, serif;
    }
    </textarea>

    Sadly this does not change anything.

    Youre quite right the code isnt in style.php.
    I deleted it again after seing that it just gave me some mistakes rather than accomplish what I was trying to do.

    Is there not a plugin option page in the WordPress admin that looks like this where you can set custom CSS styles?

    Thread Starter andreasdk

    (@andreasdk)

    Yes there is and that did the trick.

    Thank you ever so much 🙂

Viewing 10 replies - 1 through 10 (of 10 total)

The topic ‘DIfference in header on index.php and single.php’ is closed to new replies.