Home page menu keeps on changing position depending on screen resolution.

Hi, we are new to CSS and WordPress itself. We have been doing some CSS editing for these past 2 weeks so please bear with me.

We are working on this Webpage as a subdomain of our Main Company website.

The Menu on the homepage keeps on changing position when viewed from different computers with different screen resolutions.

This is the code i used to edit using Jetpack.

#main-nav {

position: relative;

top: 40px;

left: 30px;

display: inline;

}

.site-header-half-width-logo .site-title, .site-header-half-width-logo .site-description {

text-align: left;

position: relative;

top: 10px;

left: 100px;

}

also the Site Title part of the website ( The name of the Realtor ) also changes position depending on the screen resolution.

here is the code used

.site-title a, .site-title a:visited {

font-family: ‘ChunkFiveRegular’;

font-size: 60px;

font-size: 6rem;

color: #fff;

text-decoration: none;

line-height: 1.1;

position: relative;

}

Even the background picture is cut when viewed on my 23″ monitor

here is the code used:

.site-header {

width: 100%;

min-width: 100%;

min-height: 100%;

height: 149px;

background: url(http://i.cubeupload.com/mt1rLJ.jpg);

min-width: 100%;

Min-height: 100%;

height: 149px;

width: 100%;

-webkit-background-size: cover;

-moz-background-size: cover;

-o-background-size: cover;

background-size: cover;

text-align: center;

}

Also please send us instructions on how to attach screenshots for future help inquiries.

We would appreciate a prompt response.

Thank you very much.

  • Tyler Postle
    • CGO

    Hey Maria,

    Hope you're doing well today!

    Thanks for your questions.

    The Menu on the homepage keeps on changing position when viewed from different computers with different screen resolutions.

    This is what they call "Responsive Design" – meaning the widths and position of certain elements on your site will change with the screen width in order to better accommodate smaller screens.

    also the Site Title part of the website ( The name of the Realtor ) also changes position depending on the screen resolution.

    I tested this out and you're referring to how on smaller screens the "lopez" drops down below Arlene? Do you not want that?

    Even the background picture is cut when viewed on my 23" monitor

    Can you try adding this to your .site-header styles:

    .site-header {
    background-size: 100%;
    }

    Let me know how that works for you :slight_smile:

    Also please send us instructions on how to attach screenshots for future help inquiries.

    You can click the "Attach File" button beside your avatar in the comment box. That will allow you to attach several files.

    If you are posting from your dashboard, then instead just go to this link and post: https://premium.wpmudev.org/forums/#question

    Look forward to hearing back from you Maria!

    Cheers,

    Tyler

  • Maria
    • Flash Drive

    Thank you very much for working with us towards solving this issue.

    however please take a look as i have tried to do this step,

    Can you try adding this to your .site-header styles:

    .site-header {

    background-size: 100%;

    }

    Let me know how that works for you :slight_smile:

    Attached is an image of how it looks like on a 23" screen after adding the said lines.

    the picture is cut and the menu is not aligned the name and title of the REALTOR is also not aligned.. we would like it to look constantly like the 2nd image i attached.

    Thanks

  • Tyler Postle
    • CGO

    Hey Maria!

    It looks like you will need to upload a larger image so it can fit in that area instead of being scaled up to fit. This is what is causing the image to get cut off.

    Upload an image that is about 1900×149 and it will scale properly. I would keep all your content in the background image the same and just extend each end. This way content won’t get cut off in desktop monitors if they aren’t big enough.

    Hope this helps :slight_smile: let me know how this goes for you!

    All the best,

    Tyler

  • Maria
    • Flash Drive

    Still not working Tyler. I set the background to 1900 x149 but it still is getting cut. even if i change the size of the picture on the back ground it still gets stretched and gets cut on big screens. Please help as we are running out of time and the site needs to be ready for use by the week. Can you give us code that can be used to fix this immediately? Thank you.

  • Jake
    • Design Lord, Child of Thor

    Hi Maria,

    I hope your day is going well and thank you for your patience. Try adding this code to your site header class, it should fix the issue of the header getting clipped off. I’ve also outlined some fundamental issues you can expect to face below.

    .site-header{
    background-size: 100% 100% !important;
    background-repeat: no-repeat;
    }

    The issue you’re facing here is that the theme you are using is responsive and that means that the CSS rules you define will be adjusted based on the size of your browser window. It appears there is some conflict between the rules you defined in your original post and the responsive overrides. That explains why you see different results based on your screen resolution.

    There are two approaches to fixing this, the faster way would be to disable the responsive rules section in your style.css?ver3.9.2 file and then modify the layout to place things exactly where you want. This will give you a uniform look regardless of what screen you are using.

    However, if responsive design is a requirement for you, the other approach method will be to modify the rules in that section for each screen size based on how you want it to look. This means adjusting the browser window size to where you see things ‘snap’ into a different position, then adjusting rules in the appropriate sub-section under the ‘Responsive Rules’ section.

    Please let me know if this helps or brings to mind further questions.

    Cheers

    Jake

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.