WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] WordPress not useing style sheeet (3 posts)

  1. fgary308
    Member
    Posted 4 years ago #

    I have been working on building my own theme for my wordpress site and it has become clear to me that the site is not using the style sheet I have built. I am using XAMPP to test my site and have confirmed that the updated style sheet is in my theme folder on the server. I can tell that the style sheet isn't impacting my site as I set the h2 font size to 500px and the color to #3333FF (blue). The text didn't change size or color after these changes. I am using a home.php page as my main page that I am working on. Is there something special I should do to get the style.css sheet to impact my site, I thought it was as easy as putting in the sheet but maybe I need to call it in some fashion.

  2. alchymyth
    The Sweeper & Moderator
    Posted 4 years ago #

    there is normally this in header.php:

    <link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo( 'stylesheet_url' ); ?>" />

    however, even a smal typing error in the style sheet might compromise styles folowing after it:

    check with http://jigsaw.w3.org/css-validator/

    also, h2 might be part of the linkable title, in which case the style to influence the output would be h2 a { ... };

    and then there is the browser cache that holds on to old styles - try to reload the site, or to refresh the cache by pressing 'ctrl f5'

  3. fgary308
    Member
    Posted 4 years ago #

    Thank you. That code in the header fixed everything.

Topic Closed

This topic has been closed to new replies.

About this Topic