Advertisement:

Author Topic: How to setup Child theme?  (Read 15956 times)

raess

  • Full Member
  • ***
  • Posts: 240
Re: How to setup Child theme?
« Reply #15 on: August 12, 2014, 01:14:13 pm »
I can not get it to work even though I change the permissions off the folders.

My Parent Theme is (kupatana)

Exactly like this, I have done.
  • I updated from 3.3.2 through admin panel. (went like a clockwork).
  • Created a folder in oc-content/themes/kupatana-child  (with permissions 775 (rwxrwxr-x))
  • I Created a index.php in oc-content/themes/kupatana-child folder   (with permissions 664 (rw-rw-r--))
The index file oc-content/themes/kupatana-child/index.php looks like this
Code: [Select]
<?php
/*
Theme Name: Kupatana Child theme 
Description: Kupatana Child
Version: 1.0
Author: Kupatana
Author URI: http://kupatana.com
Parent Theme: kupatana
*/
?>

    Then i went to
    Admin / Appearance / Manage themes  -> but it still does not show :(

    tomshaft

    • Hero Member
    • *****
    • Posts: 862
    • Osshaft for Osclass - Add 650 posts to my total
    Re: How to setup Child theme?
    « Reply #16 on: August 12, 2014, 02:28:11 pm »
    Not sure I think it should be:
    <?php
     
    /* ... Parent Theme: name-of-your-parent-theme-folder ... *//*
    Theme Name:
    kupatana-child  (Name of child theme)
    Description: Kupatana Child
    Version: 1.0
    Author: Kupatana
    Author URI: http://kupatana.com
    Parent Theme: kupatana
    */
    Also the folder the theme is placed in should be the actual name of the theme such as:
    kupatana-child.

    Tom
    « Last Edit: August 12, 2014, 02:34:09 pm by tomshaft »

    raess

    • Full Member
    • ***
    • Posts: 240
    Re: How to setup Child theme?
    « Reply #17 on: August 12, 2014, 02:32:49 pm »
    Not sure I think it should be:
    <?php
    /*
    Theme Name:
    kupatana-child  (Name of actual theme)
    Description: Kupatana Child
    Version: 1.0
    Author: Kupatana
    Author URI: http://kupatana.com
    Parent Theme: kupatana
    */
    Also the folder the theme is placed in should be the actual name of the theme such as:
    kupatana-child.

    Tom


    unfortunately it still does not appear in Appearance / Manage themes  :/

    tomshaft

    • Hero Member
    • *****
    • Posts: 862
    • Osshaft for Osclass - Add 650 posts to my total
    Re: How to setup Child theme?
    « Reply #18 on: August 12, 2014, 02:35:16 pm »
    Did you try as I suggested in previous post?
     
    Tom

    raess

    • Full Member
    • ***
    • Posts: 240
    Re: How to setup Child theme?
    « Reply #19 on: August 12, 2014, 02:43:08 pm »
    I change index.php in kupatana-child folder to

    Code: [Select]
    <?php

    /* ... Parent Theme: kupatana ... *//*
    Theme Name: kupatana-child
    Description: Kupatana Child
    Version: 1.0
    Author: Kupatana
    Author URI: http://kupatana.com
    Parent Theme: kupatana
    */
    ?>
    « Last Edit: August 12, 2014, 02:48:41 pm by raess »

    tomshaft

    • Hero Member
    • *****
    • Posts: 862
    • Osshaft for Osclass - Add 650 posts to my total
    Re: How to setup Child theme?
    « Reply #20 on: August 12, 2014, 02:56:40 pm »
    The theme folder kupatana-child needs to be in the folder "themes".
    You currently have it in the folder named kupatana.
    oc-content/themes/kupatana/kupatana-child
    Correct:
    oc-content/themes/kupatana-child
     
    At least that is the way I understand it.
    Tom

    raess

    • Full Member
    • ***
    • Posts: 240
    Re: How to setup Child theme?
    « Reply #21 on: August 12, 2014, 03:00:57 pm »
    This is how i have it:

    tomshaft

    • Hero Member
    • *****
    • Posts: 862
    • Osshaft for Osclass - Add 650 posts to my total
    Re: How to setup Child theme?
    « Reply #22 on: August 12, 2014, 03:18:22 pm »
    Does it now show in admin - Appearances?
    If not then I am wrong about how I think it works.....
     
     
    I no longer use or have any clients using Osclass since version 3.1 except for www.osshaft.org so I haven't kept up with latest changes but based on the concept I would think it would be as I posted.
    Tom
    « Last Edit: August 12, 2014, 03:20:33 pm by tomshaft »

    raess

    • Full Member
    • ***
    • Posts: 240
    Re: How to setup Child theme?
    « Reply #23 on: August 12, 2014, 03:23:11 pm »
    Does it now show in admin - Appearances?
    If not then I am wrong about how I think it works.....
     
     
    I no longer use or have any clients using Osclass since version 3.1 except for www.osshaft.org so I haven't kept up with latest changes but based on the concept I would think it would be as I posted.
    Tom



    No it does not show in the admin - Appearances :(

    Thanks anyways :D

    tomshaft

    • Hero Member
    • *****
    • Posts: 862
    • Osshaft for Osclass - Add 650 posts to my total
    Re: How to setup Child theme?
    « Reply #24 on: August 12, 2014, 03:30:32 pm »
    We all learn from this type post so when someone does solve your problem it will be of use to all.
    Good luck.
    Tom
     
    P.s.
    Read the doc file a couple times. Is not a lot of help.....

    teseo

    • Hero Member
    • *****
    • Posts: 6169
    Re: How to setup Child theme?
    « Reply #25 on: August 12, 2014, 03:54:13 pm »
    Hi,

    I couldn't remember any theme or plugin using a dash in its name. So I have done the test, renamed google_maps to google-maps and it won't show in the list of available plugins, same with a theme. Try changing all "kupatana-child" to "kupatana_child". ???

    Regards

    raess

    • Full Member
    • ***
    • Posts: 240
    Re: How to setup Child theme?
    « Reply #26 on: August 12, 2014, 03:59:03 pm »
    I have come a little bit further with this.

    When I delete (-) in kupatana-child folder name and just have use.-  (kupatanachild) I get up in the admin panel
    Like this.

    But when I enable the child theme, I get a page with no css and other :/

    raess

    • Full Member
    • ***
    • Posts: 240
    Re: How to setup Child theme?
    « Reply #27 on: August 12, 2014, 03:59:42 pm »
    Hi,

    I couldn't remember any theme or plugin using a dash in its name. So I have done the test, renamed google_maps to google-maps and it won't show in the list of available plugins, same with a theme. Try changing all "kupatana-child" to "kupatana_child". ???

    Regards

    I noticed exactly the same thing :)

    raess

    • Full Member
    • ***
    • Posts: 240
    Re: How to setup Child theme?
    « Reply #28 on: August 12, 2014, 04:09:45 pm »
    If i use this in index.php it is actually now loading the bender theme when i hit the "Activate" And it fails to retrieve files from "Parent theme"
    Code: [Select]
    <?php

    /* ... Parent Theme: kupatana ... *//*
    Theme Name: kupatana_child
    Description: Kupatana Child
    Version: 1.0
    Author: Kupatana
    Author URI: http://kupatana.com
    Parent Theme: kupatana
    */
    ?>



    And if i use this in index.php i get error.

    Code: [Select]
    <?php
    /*
    Theme Name: kupatana_child
    Description: Kupatana Child
    Version: 1.0
    Author: Kupatana
    Author URI: http://kupatana.com
    Parent Theme: kupatana
    */
    ?>

    i get:
    Code: [Select]
    Warning: require_once(/home/kupatana/public_html/oc-content/themes/kupatana_child/inc.functions.php): failed to open stream: No such file or directory in /home/kupatana/public_html/oc-content/themes/kupatana/functions.php on line 621

    Fatal error: require_once(): Failed opening required '/home/kupatana/public_html/oc-content/themes/kupatana_child/inc.functions.php' (include_path='/home/kupatana/public_html/oc-includes/htmlpurifier:.:') in /home/kupatana/public_html/oc-content/themes/kupatana/functions.php on line 621



    If i add the functions.php from "parent theme"  to oc-content/themes/kupatana_child

    I get this error:
    Code: [Select]
    Fatal error: Cannot redeclare kupatana_is_fineuploader() (previously declared in /home/kupatana/public_html/oc-content/themes/kupatana_child/functions.php:47) in /home/kupatana/public_html/oc-content/themes/kupatana/functions.php on line 48
    /R
    « Last Edit: August 12, 2014, 04:23:07 pm by raess »

    tomshaft

    • Hero Member
    • *****
    • Posts: 862
    • Osshaft for Osclass - Add 650 posts to my total
    Re: How to setup Child theme?
    « Reply #29 on: August 12, 2014, 04:31:11 pm »
    Hi,

    I couldn't remember any theme or plugin using a dash in its name. So I have done the test, renamed google_maps to google-maps and it won't show in the list of available plugins, same with a theme. Try changing all "kupatana-child" to "kupatana_child". ???

    Regards

    @ teseo - GREAT CATCH...

    Maybe go back to beginning starting with teseo's suggestion.

    Tom
    « Last Edit: August 12, 2014, 04:41:10 pm by tomshaft »