Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Presumably a common question, but I'm having some difficulty as it's my first time editing WordPress themes.

I'm trying to create child theme based on Zincious. This is all fine for CSS, but when it comes to editing HTML, it doesn't work. I have the same file name and path as the original. Any idea what could be going wrong? All I'm trying to do for now is comment out / delete a div.

Thanks very much.

share|improve this question
    
Exactly what file are you trying to replace? –  imHavoc Aug 19 '12 at 19:23
    
One file is library.php within the includes folder. –  Sebastian Aug 20 '12 at 13:16
    
Is library.php a template? Or just a file of functions? You can only override templates in the Template Hierarchy. I'm not familiar with that theme so I can't know. –  helgatheviking Mar 2 '13 at 13:38
    
See this link it might be useful to you.This shows how to override the files in parent themes folder wordpress.org/support/topic/… –  Omkar Bandkar Feb 13 at 11:12
add comment

1 Answer 1

if it the functions file, the child theme is loaded in conjunction with it's parent, the child being loaded first.

If its the index.php file, you need to make sure your WordPress version greater than or equal to 3.0. Otherwise, your index.php file won't overwrite.

A lot of reworking of themes has happened in the last year, so make sure you check out the documentation on themes and more specifically child theme overrides.

http://codex.wordpress.org/Child_Themes

Basically, to overwrite another file, simply make sure it has the same name. If your trying to overwrite a theme specific (ie. not WordPress default theme file) file, it won't work. You'll have to overwrite at he WordPress specific theme name and go from there.

For example, if you are trying to override page.php, just place a page.php file in your child theme directory.

If page.php includes or requires some specific file in some parent theme sub-directory, you'll have to override page.php and change the include location.

I hope this helps.

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.