This thread is over two years old and may be outdated. Please create a new thread if you need help, or email us if you have an active Premium license.

CSS to set mobile padding for whole website

7 years ago · Last reply by Alex S 7 years ago

Hey there,

The padding for my site on mobile is a little wonky. It goes right up to the edges and doesn’t look great on mobile. In the page builder, I can adjust the Mobile Padding fields to get some white space on the sides. However, this doesn’t change the padding on everything on the page (the Title of a blog post goes all the way to the edges, but the body text doesn’t). Can someone please help me with CSS that will apply mobile padding to my entire site and all the elements?

I tried some of the CSS suggestions on the help forum but it wasn’t giving the desired result.

Please help! Thanks,

Patrina

This is our free support forum. Replies can take several days.

Need fast email support? Get SiteOrigin Premium

Replies

5
  1. Alex S Staff 7 years, 7 days ago

    Hi Patrina,

    Do you have a public URL where we can take a look at what’s going on?

  2. Patrina Pellett 7 years, 7 days ago

    Hey there,

    View this post on mobile:

    https://locallect.com/more-traffic-to-weebly-blog/

    In this post, I added a mobile padding of 50 px in the row element. Notice how the title of the page and title of the post is all the way to the left edge (no margin) but everything else has the 50 px margin.

    Please let me know how I can make everything have a margin on mobile devices. If there is CSS to apply to the whole page instead of having to adjust the mobile padding for every row element that would be awesome.

  3. Alex S Staff 7 years, 7 days ago

    Hi Patrina,

    To achieve what you’re after, you should edit your custom CSS and replace:

    #main {
        padding: 0
    }
    

    With:

    #main {
        padding: 0 25px
    }
    
  4. Patrina Pellett 7 years, 7 days ago

    Seems to have done the trick!

    Big thank you!

  5. Alex S Staff 7 years, 7 days ago

    Hi Patrina,

    Great to hear! :)
    Please be sure to post another thread if you have any other questions.

Replies on this thread are closed.

Please create a new thread if you have a question, or purchase a SiteOrigin Premium license if you need one-on-one email support.

Have a different question or issue?

Start New Thread