• Hello!

    I’ve tried all sorts of things to edit the position of the primary sidebar on my site. I managed to do it, however it only works on my PC’s display resolution. On mobile devices and displays with different resolutions, it’s just moved off screen and looks really weird.

    My problem is that the sidebar is not actually on the right side of the screen, meaning there’s empty white space between the sidebar and the website’s edge. How would I make it stick to the right side of the screen?

    Screenshot below:
    https://ibb.co/z6L03qn

    Thank you

    • This topic was modified 3 years, 1 month ago by Jan Dembowski. Reason: Moved to Fixing WordPress, this is not an Developing with WordPress topic

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • My Name

    (@mhosseini80)

    Hi,
    Remove or comment the “float” CSS style.

    .sidebar-main {
        position: relative;
        float: right;
        right: -111.5%;
    }

    filename:
    https://plavalcek.si/wp-content/themes/big-store-child/style.css?ver=1.7.0.1633437188

    Thread Starter jazzu

    (@jazzu)

    Hi @mhosseini80 !

    Thank you for your feedback. I removed the float part from the code and the sidebar stayed the way it was. If I edit the “right” part of the code to for example 0%, the sidebar goes to the original position. If I leave it at -111.5%, it still only works on certain display resolutions, so that doesn’t solve the problem.

    The width and everything of the sidebar is okay, I just want it to stick to the right side of the website on any device.

    Thank you for your time!

    My Name

    (@mhosseini80)

    I had to say “right” CSS Style, sorry about it,
    anyway, add or edit these styles:

    #primary{
        width: 70%;
    }
    
    .sidebar-content-area {
        	
    }
    
    .sidebar-main {
        width: -webkit-fill-available;
    }
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Sidebar Position’ is closed to new replies.