1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Child theme won't override a css.php file

Discussion in 'WordPress' started by web_junkie, Apr 19, 2014.

  1. #1
    Hi I was wondering if someone has run with a similar problem. I have a child theme that I am working on and I am able to overwrite the styles.css file and other templates .php files (both on the root folder of the theme). But I am trying to edit a file that is in the /css folder, something like dynamic - css .php ...But when I copy it to the same location to the child theme and edited it does not overwrite the parent file.....Can someone help me ...Thanks
     
    web_junkie, Apr 19, 2014 IP
  2. carlo75

    carlo75 Active Member

    Messages:
    129
    Likes Received:
    14
    Best Answers:
    1
    Trophy Points:
    80
    #2
    Hi web_junkie,
    can explain better what you need... I don't understand sorry... but have you activated the child theme?
     
    carlo75, Apr 23, 2014 IP
  3. web_junkie

    web_junkie Active Member

    Messages:
    98
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    91
    #3
    Hi, Thanks for the reply...... ok. I have activated the child theme, and as you know you have to have a style.css file in the child theme in order to overwrite the parent style.css. The same goes for other template files(.php files). Which it has worked fine so far. Now there is a folder in the parent theme call css which has all of the other .css files for the theme. When I copy and paste one of the files in this css folder to the child theme, it does not override the corresponding file in the parent theme..... I hope this makes better sense. ....I jsut want to know why is this, since it works for other files.

    Thank you.
     
    web_junkie, Apr 23, 2014 IP
  4. carlo75

    carlo75 Active Member

    Messages:
    129
    Likes Received:
    14
    Best Answers:
    1
    Trophy Points:
    80
    #4
    You can try to import in the child main style.css the css inside the "incriminated" folder, something like that:

    @import url('/css/yourfile.css');

    If it doesn't work, you can try to edit your header.php and change this bloginfo('template_directory'); with bloginfo('stylesheet_directory');
     
    carlo75, Apr 23, 2014 IP