problem – change header size using a child theme

  • reza3d

    #1706

    Hi

    I had to add a new topic because the related topic is closed.

    I created a child theme to change the theme.

    I created a style.css and functions.php and put them in graphene-child folder.

    I used some codes to change the header size like what you had said in other posts.(some codes in style.php and some codes in functions.php). I activated graphene-child in admin page.

    Now I have two two problems:

    1- the header size didn’t change

    2- rtl support that i had created using (fa_IR.php) does not work any more (<?php $text_direction = 'rtl'; ?>)

    please help

    Mod

    Kenneth John Odle

    #16944

    Link to site?

    reza3d

    #16945
    Mod

    Kenneth John Odle

    #16946

    Reza, in your child theme’s stylesheet, you have

    /*
    #header{
    background-color:#000;
    background-repeat:no-repeat;
    height:960px;
    width:50px;
    }
    */

    I think you meant:

    #header{
    background-color:#000;
    background-repeat:no-repeat;
    width:960px;
    height:50px;
    }

    Don’t include /* and */ as these are used to add comments and anything between them is ignored by your browser. Also, you had height and width reversed.

    Try those changes and see what happens.

    Ken

    reza3d

    #16947

    Dear kim,

    I changed style.css as you said and it worked well.

    but why some elements are still left to right?

    my father graphene-theme is set on RTL but after using graphene-child, some elements are still LTR.

    Thanks

    Reza

    Admin

    Syahir Hakim

    #16948

    Open up the theme’s functions.php file, and find these code block:

    function graphene_main_stylesheet(){
    wp_register_style( 'graphene-stylesheet', get_stylesheet_uri(), array(), false, 'screen' );
    wp_enqueue_style( 'graphene-stylesheet' );
    }
    add_action( 'wp_print_styles', 'graphene_main_stylesheet' );

    Replace that with this:

    function graphene_main_stylesheet(){
    wp_register_style( 'graphene-stylesheet', get_stylesheet_uri(), array(), false, 'screen' );
    wp_enqueue_style( 'graphene-stylesheet' );

    wp_register_style( 'graphene-stylesheet-rtl', get_template_directory_uri() . '/rtl.css', array(), false, 'screen' );
    if ( is_rtl() ) wp_enqueue_style( 'graphene-stylesheet-rtl' );
    }
    add_action( 'wp_print_styles', 'graphene_main_stylesheet' );
Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.
Do NOT follow this link or you will be banned from the site!