Sunday, 22nd Jan 2017

«

»

Print this Post

Graphene Child Theme Template

It is always better to use a child theme while doing changes to the site / theme. But, as a volunteer at the Graphene Theme Support forum, I see so many people struggling to set up a child theme for the Graphene theme. So, I’ve decided to create a child theme template for the Graphene theme.

You can download the child theme template in this page. It has two files. A ready to use style.css file which is mandatory, and a blank functions.php file.

Download Graphene Child Theme

Click on the above image to download the Graphene Child theme

How to install it?

Download the child theme from the above link. Then go to Appearance –> Themes –> Install Themes and click on Upload. Browse the downloaded theme and hit the Install Now button. Activate the theme in the next step.

Or,

Extract the contents of the graphene-child.zip file and upload the graphene-child folder to the wp-content/themes/ directory using FTP. Then go to Appearance –> Themes and Activate the Graphene Child theme.

(If you’re using a custom header image, then, you need to restore the header image after activating the child theme. The same applies to background images and custom menus as well.)

Have any doubts? Feel free to post a comment or create a thread in the Graphene theme support forum.

– Prasanna SP

Short Link:

About the author

Prasanna SP

Student | WordPress Dev | Tech Blogger | Interested in GNU/Linux, FOSS, PHP, Drupal, WordPress, Ethical hacking, Photography, Painting, Literature etc..

65 comments

6 pings

Skip to comment form

  1. Josh

    Love your idea for the child theme download!! Nice work. I’ll be sure to send people your way as they struggle with this.

    Thanks!!!

    1. Prasanna SP

      Thanks Josh!

    2. Josh

      Yes Sir. And just to expand a little, any custom background will also need to be replaced.

      (I’ve already referenced your page here twice ) 🙂

      1. Prasanna SP

        Ah! Yes, thanks for notifying this. I’ve updated the post.

        (I’ve already referenced your page here twice )

        Thank you so much! It’s been downloaded 38 times within one day! 🙂

  2. Helmut

    Hello Josh!
    Thanks for Your Support..

    unfortunatly i get this Message:

    ?> Fatal error: Cannot redeclare _check_activewidgets() (previously declared in /customers/0/3/f/doc-germanicus.net/httpd.www/dox/wp-content/themes/graphene-child/functions.php:4) in /customers/0/3/f/doc-germanicus.net/httpd.www/dox/wp-content/themes/graphene/functions.php on line 2681

    🙁

    Any sugestions..?

    Helmut

    1. Prasanna SP

      Hi Helmut, can you please give me the code that you entered in the child theme’s functions.php file?

      use http://pastebin.com to share codes

  3. Helmut

    I use the Code of the Download-ZIP..

    Í´m looking for maybe changed code..

    One Moment please!

  4. Helmut

    Hi Prasanna,
    here the style.css:
    http://pastebin.com/qX2SGz6m

    Its looks like the original, i think..

    The functions.php
    http://pastebin.com/T6LrGV5H

    Oooh.. there is some extra code. 😉

    1. Prasanna SP

      Oops! What’s that code in functions.php? Who added that?

      1. Helmut

        I have no glue!
        Every time i load the right file up, it was overwritten by the first call off the child-theme..

        I set it to 0644, so it runs ones, but then: its the same..

        Only a different error-message:
        Warning: Cannot modify header information - headers already sent by (output started at /customers/0/3/f/doc-germanicus.net/httpd.www/dox/wp-content/themes/graphene-child/functions.php:2) in /customers/0/3/f/doc-germanicus.net/httpd.www/dox/wp-includes/pluggable.php on line 866

        🙁

        1. Helmut

          Its so Funny.. or superspicious..? ggg

          I try the this:I taking the functions.php from the “Mother”theme, delete all, but the “comment-Header” and the start and endpoint (PHP)

          http://pastebin.com/6i2KT3Tj

          Now its seens to work OK..
          stay on tuned! 😉

          Thank You!

          1. Prasanna SP

            That is not a good solution.. Clear everything in child theme finctions.php and try again..

  5. ems

    Thanks so much for this post!! I’m a total newbie and can not figure out what to do with your file once I download it to my desktop. I am using bluehost for my website, I tried uploading the file into my file-manager but can’t seem to create a folder to put it in?

    I’m in way over my head…hopefully you can help? 🙂

    thanks!

  6. Corine

    Thank you so much. I am absolutely not technical but loved the theme because of its easy of use. I didn’t know or understand how to create a child theme. Just to make sure though….. will any changes I make stay now even if there is an update or do I need to do something else to avoid losing changes?

    Thanks,

    Corine

    1. Prasanna SP

      Any changes done to the child theme will retain even after the parent theme update. That’s what the purpose of using child theme for theme modifications!

  7. Helmut

    Hi Prasanna! 😉

    Its seems that some Plugins overwrite the functions.php, or put there additional code in it.
    And in the functions.php of the “mother”theme to..
    ==> ERROR..! 🙁

    How can I prevent this Prob..?

    Thanks!

    Greetings from Stuttgart,

    Helmut

    1. Prasanna SP

      Hi Helmut,
      That’s strange! Can you list out the plugins you’re using?

  8. Dan

    Thanks so much for this post!! I’m a total newbie and can not figure out what to do with your file once I download it to my desktop. I am using bluehost for my website, I tried uploading the file into my file-manager but can’t seem to create a folder to put it in?

    I’m in way over my head…hopefully you can help?

    thanks!

    1. Prasanna SP

      Hi Dan, please see “How To Install” section in this post.

      Go to Appearance –> Themes –> Install Themes and click on Upload. Browse the downloaded child theme and hit the Install Now button. Activate the Graphene Child theme in the next step.

      Let me know if you find any difficulties in installing the child theme.

    2. Dan

      I’m a bozo…thanks!

  9. Eleni

    Hello!
    I read in forum that when we copy the id of the page that we don’t want to be viewed in first page, we write in options/display/css code this:

    .post-427 {
    display: none;
    }

    (And post-427 is the page id that we don’t want to display. )

    I try to do this, but nothing happens. The page “ΕΜΕΙΣ” (in my site the page id is “.emeis” is always there.
    Maybe I do something wrong?

    I wrote:

    .emeis {
    display: none;
    }

    Is this ok?

    1. Prasanna SP

      Hi Eleni,
      ID of the ΕΜΕΙΣ page in your site is 479. (Not 427)

      So, try this CSS code,

      .post-479 {
      display: none;
      }

      Let me know if it doesn’t work.

      1. Eleni

        Thanks a lot!!!!!!!!!!!!!!!
        It works!!!!

  10. Derek Haines

    Thanks so much for this!!! Brilliant. At last I’ve got a child theme that works!

    1. Prasanna SP

      Thanks Derek! 🙂

  11. Eleni

    I really really appreciate your great help Prasanna!!!!!
    Thanks a lot!

    It works!!!!!!!

    1. Prasanna SP

      Thanks Eleni! 🙂

  12. Bluebox

    Hi Prasanna, I got the child theme to work thank you 🙂

    I have had issues with drag n drop multi image uploads, they just stick on crunching and also the top bar… it’s the only customisaton I’ve put in the child theme css and although it works, the code gets published to the top of the page also:

    http://79.170.44.93/west-tek-ltd.com/

    any ideas why?

    1. Prasanna SP

      Hi Bluebox,

      About drag and drop media files, temporarily disable all plugins and try again.

      Top bar issue,
      sprite_h.png image is not there in your graphene-child/images directory. So, it is causing the problem.

      1. Bluebox

        Hi Prasanna,

        I deactivated the only active plugin and this images go up but stick on ‘crunching’… any ideas?

        I also published the images folder to the graphene-child directory and although the sprite_h.png image now shows in the header it has not fixed the text that still shows across the top of the pages (and in some of the image upload popup screens).

        Any advice would be great 🙂

        Bluebox

        1. Bluebox

          Hi Prasanna,

          Any ideas about this naughty text that loads at the top of the page:

          #top-bar { background: url(images/sprite_h.png) left -596px repeat-x #313130; border-bottom:1px solid #222; height: 10px; position: relative; z-index: 10; }

          you can see it here: http://79.170.44.93/west-tek-ltd.com/

          I can overcome this by removing the child theme but I really want to use the child theme as advised by yourself and other moderators of the Graphene forum…

          Please let me know.

          Many thanks

          Bluebox

          1. Prasanna SP

            Hi Bluebox, your custom CSS is somehow being added to the top of the pages. Did you add anything to the header file?

            I could inspect this if you give me temporary access to your site’s admin area.

            1. Bluebox

              Hi Prasanna,

              Sorry for the late reply… my daughter has been unwell.

              Thank you for your kind offer to inpect the site… can you email me and I’ll send you a private email with access details?

              Many thanks

  13. Fathima

    I am getting Parse error when I try to download this Graphene Child Theme Template. What should I do now?

    1. Fathima

      Parse error: syntax error, unexpected ‘”‘ in /home/prasazc8/public_html/wordpressblog/wp-content/plugins/download-monitor/download.php on line 674

      1. Prasanna SP

        It should be working now. Try again. – Graphene Child Theme.

        Sorry for the inconvenience ..

  14. Fathima

    Thanks for the child theme. I don’t have much knowledge technically.
    Can you please tell me if in future I should work on my blog using child theme only
    Also if I am using child theme for modifications and it is working perfect, how will it affect in the parent theme.

    1. Prasanna SP

      It is always good to make your customizations using a child theme. So that you won’t miss out your customizations on theme update.

      Child theme modifications doesn’t affect parent theme unless your custom functions or CSS is buggy.

  15. Ann Baker

    thank you Prasanna! I had been struggling for hours following other instructions: Your download worked. Very grateful!

    1. Prasanna SP

      You’re welcome Ann Baker!

  16. Andrea

    Dear, i hope that you will be so kind to help me.
    I’m a beginner, and use a graphene thema. The first time, last sunday, i made a child graphene, like you explained (uploading a zip file) and eveyting wsa good. After, i can try to use child; in my ignorance, i done:
    1) select php file in child
    2) select header inside this
    3) copy in it the code, suggested in forum support’graphene, for completing plugin moving slide

    This operation had killed my site.. instead to see my site, i can only see the small box ,called “search”

    With artisteer i can try to upload primitive thema , and it done ok; after by thema i reloaded graphene “daddy, principal”,
    When i can start to reload a child graphe, web site shurt down like explained.

    So now i cannot use a graphene child; can you help me? My site: www. wingsd.it

    Please help!
    Thanks a lot
    Andrea

  17. Alain RONK

    Hello Prasanna, how are you ?

    I asked Josh but he did not respond, it may be on vacation …

    I find the modification for my personal 404 !
    Look here : http://www.modelisme-racer.fr/xc5cv8fkjj,;:!85875dfdvbn,;klmhjklcvn,l

    But, I have a question :
    I have the child theme for Graphene.
    If I place the file 404.php in the theme child, and if there is an update of the theme that has a modification in this file, I would not have the modification !
    What is the solution for all these files, except functions.php and style.css, please?

    Best regards
    Alain
    Website : http://www.modelisme-racer.fr

  18. Adam @ TPR

    Awesome write up … can’t believe I didn’t do this before …. nice and easy. No more re-tracing all my custom steps with every update.

    1. Prasanna SP

      Glad you’ve found it useful. Thanks Adam!

  19. globe-tukuru

    Your child theme work well!
    Thank you very much!

    1. Prasanna SP

      Thanks for your contributions globe-tukuru!

  20. Mango

    Greetings Prasanna,

    This is very timely information. One of my sites corrupted overnight for unknown reasons, possibly a rubbish plugin. Anyway today I am rebuilding from scratch as the original site was getting a bit aged etc, and was thinking about which theme to use.

    The Theme upgrade is always an issue as your custom mods get trashed unless you have a child theme, but many people struggle with the concept of Child Themes. That issue is now solved and my decision about which Theme to use is easily made.

    Just a question; will this Child Theme work with the new version 8 update? And how far away is version 8?

    By the way, I really like your Theme!

    Thanks again,

    Mango
    Bangkok

    1. Mango

      Sorry, I meant Graphene version1.8 of course.

      Been a long night!

      Mango

    2. Prasanna SP

      Hi Mango! This Child theme works with any version of Graphene theme, unless you change the name of parent theme! 🙂

      Sorry to hear that your site got corrupted. Do you have back ups of your files and databases. If you have them, you can restore your site with those files. Let me know if you want any help from me to fix your site.

  21. Andrea155

    Hi Prasanna, and thanks for your work! I’m a beginner using Graphene theme .. i had installed a portal child, but my function php (portal child, function php) is completely emty… this is a very problem for me, because i cannot past any modification (copied from support forum) it doesn’t work.. from control panel i n word press i can only see
    my code in the higjest part of site…

    my intersed is only obtain rotation header images.. i undesrtand that i have to modify php function but:
    1) how
    2) whi ch codes insert?

    Thanks
    Andrea

    1. Prasanna SP

      Hi Andrea!
      You need to put any php functions/code between opening (<?php) and closing (?>) php tags. Otherwise it’ll break the theme.

      Example of child theme functions.php

      <?php
       
      // Some code here
       
      ?>

      Read more about php tags and basics here and here.

      1. Andrea155

        thanks!!! you have fixed my crashed site.. now iot works perfectly!

  22. boxboy

    Using this. BTW is good.

  23. Neil

    Hi, I just wanted to say thanks for the child theme. I have it installed on two of my Graphene sites and it works just fine.

    However as a newbie I have what is probably a stupid question. When the next Graphene parent update comes along do I simply click update on the WordPress dashboard without making any changes to the installed child theme?

    Hope that makes sense.

  24. Andrea155

    Hello,
    I have a big problem with the site Graphene has crashed. What I wanted to do was hide in the footer the written word press.

    What I did:
    1) I put in the child function.php code written by developer:
    < ? php graphene_filter_gettext function ($ translated, $ original, $ domain) { $ strings = array ( 'Powered by% 1 $ s and the% 2 $ s.' => 'This site does not have Super Cow Power!'
    );
    if (empty ($ strings [$ original])) {
    $ translations = & get_translations_for_domain ($ domain);
    $ translated = $ translations-> translate ($ strings [$ original]);
    }
    return $ translated;
    }
    add_filter ('gettext', 'graphene_filter_gettext', 10, 3);
    >

    2) crashed: browser send me write: in salvatoristudioingegneria.com / httpdocs / wp-content / themes / graphene-child total
    3) by ftp i try to delete code (orihìginally child function.pho WAS EMPTY, is Prasanna method)
    4) Also with php function child emty not work

    Is there a way to change daddy theme via ftp? Child theme is crashed, and site is down?
    And away torstore child dunction.php (I saw it emty, blank)

    Can you help me?

    Thanks

    PLease help

    1. Prasanna SP

      Hi Andrea, I’ve answered your question in the graphene theme forum. please read this post.

      Please put code in <code> tag while posting comments here.

  25. Andrea155

    Thanks Prasanna for helping, i tryed to insery your codes. doesn’t work.
    site is down. basically, is it possible to re load a php functionchild?
    if you would an acount to see it, only by ftp, i sent you by facebbok (you have accepeed friendeship)
    Terrible sorry, but i think to have done myself serious damage in my site

    1. Prasanna SP

      Okay, I’ll try to fix it. Send me FTP login details through Facebook.

  26. Robert Batson

    Would this be right to yuse for version 3.5.1?
    Thank you

    1. Prasanna SP

      Hi Robert Batson!
      Yes, you can use it with any version of Graphene and WordPress.

  27. Ernest

    High like your work I am trying to gain a little logic to all of this. Maybe you can see where I am making a mistake. I have add the code below to my child theme style.css file but I get no change, I have tried for or five of your scripts but none will do what they should. I am using the child theme that I download loaded from your site

    THIS WILL NOT WORK ON MY SITE

    #header-menu-wrap {
        margin-top: -241px !important;
        z-index: 15;
        position: fixed !important;
    }
     
    #container {
        margin-top: 35px;
    }

    THIS WILL NOT WORK ON MY SITE

    #header-menu, #secondary-menu {
        display: table !important;
        margin: 0 auto !important;
    }

    BUT THIS WORKS OK

    body {
    	background-image: none
    }
    body.custom-background {
    	background-color: #F1F1F1;
    }
    body {
    	position: relative;
    	background-image: url('http://sseepanel.com/wp-content/themes/shanice/images/promo-light.jpg');
    	background-repeat: no-repeat;
    	background-position: center top;
    body {
    	color: #2C2B2B;
    	font: 12px/18px arial;
    }
    html, body, h1, h2, h3, h4, h5, h6, p, img, ul, ol, li, form, fieldset {
    	border: 0 none;
    	margin: 0;
    	padding: 0;
    )

    Thank You

  28. Ahmed Elseoudy

    Thanks a lot for the wonderful theme, all is working well with the child theme too but I´ve a problem with the Header Menu.

    It´s not taking the same order that I´ve already made to the mean theme. I go to customize theme then navigation and then I choose the header menu to b the menu that I´ve prepared already but when I make refresh it doesn´t go well and come back to select.

    can u help me please ?

    1. Prasanna SP

      Did you save it after assigning a custom menu to the Header Menu area?
      Link to your site?

  29. Mackenzie

    This download was extremely helpful. This is my first attempt at doing anything like this. I’ve been trying to two days to successfully create a child theme and no matter what I did or how many tutorials I watched it would never work. It turns out I didn’t have a functions.php document but nowhere said I needed one!
    Anyway, I wish I would have found this sooner, it would have saved me so much time!

  1. How to change / translate a string in Graphene Theme » Prasanna SP

    […] Here is a custom function to change or translate a string in graphene theme without messing up with parent theme files. This function goes in your child theme’s functions.php file. So, if you are not yet using a child theme, get it now. […]

  2. Grapheneテーマ/ 子テーマのテンプレート » 自分めも

    […] Graphene Child Theme Template […]

  3. Graphene Slider on other pages » Prasanna SP

    […] already using child theme in your site, you can skip 1st and 2nd steps) Important!See – Graphene Child Theme Template. It has all the necessary files for your theme […]

  4. How to add date to Graphene Theme Top Bar » Prasanna SP

    […] This method requires no plugin, but involves editing child theme’s functions.php file. So, if you’re not using child theme yet, go get it! […]

  5. Animate Return to top using jQuery in Graphene Theme » Prasanna SP

    […] The scripts I mention here need to be added to child theme of Graphene Theme. So, if you’re not yet using Graphene Child Theme, get it here. […]

  6. jQuery drop down menu in Graphene Theme » Prasanna SP

    […] Note: The scripts I mention here need to be added to child theme of Graphene Theme. So, if you’re not yet using a Child Theme yet, get it here. […]

Leave a Reply

Your email address will not be published. Required fields are marked *

Please put your code snippet between <code> and </code>. Comment moderation is in use. Please do not submit your comment twice -- it will appear shortly.