WordPress.org

Forums

Hueman
[resolved] Adding responsive.css file to child theme.... (11 posts)

  1. nirurin
    Member
    Posted 11 months ago #

    This one is probably me doing something very basic, but wrong.

    I have downloaded and am using the sample child theme from the hueman site. It's activated.

    I have added a function to the functions.php to fix a problem. (sharing posts to facebook wasn't also sharing the featured image, needed to add some info to the headers of posts. If the author reads this, maybe its something that needs fixing?) Anyway the new function in the child themes functions.php works as it should.

    However the other change I wanted to make, was in the responsive.css file. I was making some tweaks to when the sidebars disappear on small screens.
    If I make the changes on the original themes responsive.css, it works as it should. But I dont want to do that, I want to make the change on the child theme.

    So I make a responsive.css file in the child theme, copy the whole of the old respnsive.css contents into it, and make the changes I need.

    but on the site, nothing happens. No matter what I do, the Original responsive.css file is what is always used. The one I have in the child theme is ignored.

    I've done googling and whatnot, and tried a few things, but as far as I can tell I have the files set up correctly... something somewhere is just causing my child theme file to be bypassed.

    The style.css in the child theme seems to be working as it should, as is the functions.php (as I said before).

    Hopefully this is enough info for someone to give me a hint as to where I'm going wrong!

  2. CrouchingBruin
    Member
    Posted 11 months ago #

    What is your site's URL?

  3. nirurin
    Member
    Posted 11 months ago #

  4. nirurin
    Member
    Posted 11 months ago #

    Though the responsive.css page is now totally blank in the child theme, because it wasn't doing what I wanted it to do anyway and I didn't want any unwanted side effects. If you want me to put some code or something in there let me know. The file itself is still in the theme, its just an empty page

  5. CrouchingBruin
    Member
    Posted 11 months ago #

    Yes, can you please set up some CSS that targets some code on your site so I can see if it's being imported in correctly?

    Thanks.

  6. nirurin
    Member
    Posted 11 months ago #

    such as? I'm pretty rusty at this whole thing, its been a long time since I did any website work.

    I can copy the old responsive.css file and paste it all in, but im not sure if you would be able to tell the difference

  7. nirurin
    Member
    Posted 11 months ago #

    I have pasted in the info from the old responsive.css, and changed sidebars 2's min-width to 280 from 480.

    This should mean the sidebar stays on the side until the page is very narrow. but it doesnt make the change.

  8. Alexander Agnarson
    Member
    Theme Author

    Posted 11 months ago #

    Hi!

    If I make the changes on the original themes responsive.css, it works as it should. But I dont want to do that, I want to make the change on the child theme.

    Good - that's the right way to do it. If you check Theme Options > Help dropdown, and then go to the theme documentation, under the section "Child Theme", you will see how load a specific CSS file from the child theme instead of the parent theme there.

  9. nirurin
    Member
    Posted 11 months ago #

    Hah, I have to admit I didnt spot that little button up in the corner. I'll take a look

  10. nirurin
    Member
    Posted 11 months ago #

    And yeh that answers it, there is a linking function that needs to be transferred across too. Thanks for all your help :)

  11. Alexander Agnarson
    Member
    Theme Author

    Posted 11 months ago #

    :-) Glad it works.

Reply

You must log in to post.

About this Theme

About this Topic

Tags

No tags yet.