• Resolved mbdk

    (@mbdk)


    Hi guys,

    At work we’re redoing our intranet and we chose Twenty Seventeen.

    I have created a child theme following the instructions at https://developer.ww.wp.xz.cn/themes/advanced-topics/child-themes/ – so far so good. But some of the modifications that I made aren’t executing.

    (1) I have a <ul> with some links. For some reason, even tho the style.css has no text-decoration: underline; the links are still underlined. I have used the Inspect Element tool of my browser and changed the color of the links, and added text-decoration: none !important; but there is a line coming from somewhere, just can’t find where. I’m using the theme’s original style.css only modifying some things here and there.

    (2) I want to change some texts in some PHP files (translate from English into Danish without using any plugin). I have copied pasted those files in the child theme’s folder in the same paths as the parent theme, but for some reason if I don’t change those same lines on the parent theme, the changes don’t happen. An example is on index.php, the following line:

    <h2 class="page-title"><?php _e( 'Posts', 'twentyseventeen' ); ?></h2>

    Instead of “Posts” I have another word.

    The same issue happens with the files:

    • inc > template-tags.php
    • template-parts > page > content-front-page.php
    • template-parts > post > content.php

    How do I solve these issues?

    Thanks in advance.

Viewing 3 replies - 16 through 18 (of 18 total)
  • Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    The only file that is not reacting to changing that one word is template-tags.php

    That’s not a template file and so it doesn’t follow the same rules as templates for modifying it: http://themes.svn.ww.wp.xz.cn/twentyseventeen/1.4/inc/template-tags.php

    To override a function in there you can sometimes copy the function, paste it into your Child Theme functions.php file and modify it there. But you need to tell us specifically what you want changed and we can advise on that.

    • This reply was modified 8 years, 5 months ago by Andrew Nevins.
    Thread Starter mbdk

    (@mbdk)

    Oh good grief thank you! That did it!

    I have one extra question: I have one link on my main menu that lists all the posts under a category. The page title is “Category: <name of category>”. Where in WP is the word “category” generated, and can I translate it into another language? This is a nice to have.

    Thread Starter mbdk

    (@mbdk)

    Nevermind, I found my answer about removing the word “Category” on this link: https://gretathemes.com/guides/remove-category-title-category-pages/

Viewing 3 replies - 16 through 18 (of 18 total)

The topic ‘Problems with modifying child theme’ is closed to new replies.