• Resolved caefavsvs

    (@awa4000)


    I’m attempting to set up a child theme for twentyeleven at my website, https://www.ironandiron.com.

    I’m trying to figure out why the child theme remains unformatted even though I’ve included the @import command.

    Here’s what I have in my child style.css file:

    /*
    Theme Name: Twenty Eleven Child
    Description: Child theme for the Twenty Eleven theme
    Author: Anthony Ashley
    Template: twentyeleven
    */
    @import url (“../twentyeleven/style.css”);

    Any help is greatly appreciated!

Viewing 8 replies - 1 through 8 (of 8 total)
  • 1.Get rid of the space in the child theme’s folder name.

    2. There’s something wrong with your child’s style.css file. It is not being parsed by the server. Ensure that you only use a text editor to create it, save it in UNIX format/ANSII encoding and upload it in ASCII format.

    Thread Starter caefavsvs

    (@awa4000)

    Thanks for the help! I changed the folder name and deleted/uploaded the style.css file a few times.

    Using TextWrangler, I made sure the file was in Unix format and experimented with the Unicode (UTF-8, no BOM) and (UTF-8) encoding options. There is no ANSII specific format. Is UTF-8 correct or should I look for a different editor?

    While Wrangler offers ASCII encoding (gave it a shot), I don’t know what you mean by uploading in ASCII format (bit of a newb). I’ve just been saving text files and uploading via FTP without any upload format options.

    Am I on the right track? Thanks again.

    Not familiar with TextWrangler, I’m afraid. Any chance you could re-save the file in TextEdit?

    As for uploading, most FTP clients are configured to automatically upload text files in ASCII format (as opposed to, say, a .jpg which is uploaded in binary format) but just check the settings in your FTP client to ensure that .css is listed as a text or ASCII file type.

    Thread Starter caefavsvs

    (@awa4000)

    So I tried multiple text editors, and multiple variations of encoding. Do you think it’s definitely the css file or are there other variables I’m missing?

    Gut instinct says that it’s an issue with the child’s.css file. The parent’s stylesheet is exactly where it should be. Try using:

    @import url(../twentyeleven/style.css);

    Thread Starter caefavsvs

    (@awa4000)

    I don’t understand what changed but I copied the @import command you posted and it worked! Esmi, you are my hero. Thanks!

    For anyone reading this in the future the default TextWrangler settings were not the problem.

    Glad to hear that it’s working now.

    Thanx Esmi.. this helped me too!! ??

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘@import command not working in child theme’ is closed to new replies.