[Resolved] Responsive footer

  • Author
    Posts
  • #4363

    PSBakh
    Participant

    Hey guys,

    Quick question re: footer

    I used Ultra to build a corporate site for a client, and then copied the styling across to create a couple of holding pages for them, for off shoots of their business.

    However I notice that the footers behave differently between the websites:

    http://www.regentsparkhealthcare.com/ – as you can see, when resized for mobile, the widgets stack one on top of the other (on a side note, is there a css code i could use, to align the widgets to the center of the screen in this mode?)

    http://www.rphc.co.uk/ – on here however you will see that the footer just scales down and looks like a bit of a mess.

    I’m not sure what’s different between the two websites, as I used the same theme and copied a lot of the css over, so your help is greatly appreciated!

    Thanks 🙂

    #4370

    Andrew Misplon
    Keymaster

    Hi PSBakh

    Good to hear from you.

    Have you perhaps made progress with this question? Both footers now seem to be behaving in the same way.

    You could center everything in the footer as follows:

    /* Footer */
    @media (max-width: 768px) {
    	.resp #colophon .widget {
        	text-align: center;
      	}
    }
    #4401

    PSBakh
    Participant

    Hi Andrew!

    Sorry for super late response! Yes, turns out it was a blunder with the actual CMS, so I reinstalled WordPress and that seems to have fixed the issue.

    Thank you for the code above, I will implement it in the websites asap.

    #4402

    Andrew Misplon
    Keymaster

    Awesome 🙂 Glad to hear you’ve made progress.

    #4467

    PSBakh
    Participant

    Hey Andrew,

    It seems that the above problem has returned. I’m not entirely sure how to go about fixing it – I have reinstalled WordPress, and updated it to the most recent version, however it seems to jus revert back it its old ways.

    Any thoughts?

    Thank you!

    #4468

    Andrew Misplon
    Keymaster

    Thanks for your reply. The problem is that all of the normal body classes that Ultra prints and relies on are missing. There are two body tags which is strange. I think I’ve seen this in the case of domain parking or what I would consider abnormal hosting redirects. Is there anything like that happening here?

    You can see the problem if you inspect the page source:

    <body data-gr-c-s-loaded="true">
    <body>

    Two opening body tags and no body classes.

    There should only be one body tag and it should look something like this:

    <body class="home page page-id-4 page-template page-template-page-templates page-template-full-width-no-title page-template-page-templatesfull-width-no-title-php siteorigin-panels siteorigin-panels-home group-blog one-column full resp resp-top-bar" data-gr-c-s-loaded="true">

    Here is a similar case: http://wordpress.stackexchange.com/questions/198563/two-body-tags-on-all-wp-pages-regardless-of-theme.

    Does this problem persist if you switch to Ultra parent theme?

    (A quick reminder that ideally, you shouldn’t have the entire Ultra parent style.css contents in your child theme, that can cause lots of update issues, ideally you should only have the edited CSS rules and new rules in the child style.css file. At the moment there is a lot of duplication.)

    #4469

    PSBakh
    Participant

    Thank you for your speedy response.

    As far as I am aware – there are no abnormalities in regards to the hosting.

    I’ve just checked and the problem does persist when I switch to the parent theme.

    Re: style.css contents – I’m afraid I’m not very savvy when it comes to this kind of thing, I’m really more of a designer than developer, I used the child theme template available for download on your site and just changed the info regarding the site name and author?

    What can I do to resolve this?

    Thank you!

    #4470

    Andrew Misplon
    Keymaster

    The child theme challenge is not an easy fix. You’d need to use a program like DiffMerge: https://sourcegear.com/diffmerge/ and compare your child style.css with the original in order to find the rules that you’ve edited and the new rules. You don’t have to do this, it’s up to you.

    Try this, switch to any default WordPress theme like Twenty Sixteen, check your source code. This is what the body tag looks like when I view the source code with Twenty Sixteen activated and all plugins disabled:

    <body class="home blog logged-in admin-bar hfeed customize-support" data-gr-c-s-loaded="true">
    

    Note the body classes. Do you have classes in your body tag when switching to Twenty Sixteen with all plugins deactivated?

    #4473

    PSBakh
    Participant

    Hi Andrew,

    I just did as you suggested and changed to Twenty Sixteen with all my plugins disabled – and there appear to be no body classes at all in my source code. What does that mean?

    Thank you

    #4474

    Andrew Misplon
    Keymaster

    Thanks for confirming. I have seen this issue come up, a long time ago, but can’t remember exactly how it was resolved. When you enable 2016 with no plugins, if you see two body tags, one inside the other:

    <body>
    <body>

    that’s something you can ask your hosts about, see if they know anything. Random ideas that come to mind are hosting forwarding like parked domains. I’m not quite sure at this stage.

    #4475

    PSBakh
    Participant

    Ok, I’ve contacted the developers that initially built the sites back in 2012 or so, hopefully they can resolve this.
    Thank you for your help 🙂

    #4476

    Andrew Misplon
    Keymaster

    Hope you can solve. You can also try comparing this hosting setup with the site that works and try figure out what is different.

Viewing 12 posts - 1 through 12 (of 12 total)

You must be logged in to reply to this topic.

Scroll to top