Home>Support>Center Text on Mobile Only

Center Text on Mobile Only

I would like to have the red and green text on my page centered when viewed on mobile but left aligned on computers. Could you please help me with the coding for this?

Thank you,
Kristin

URL: http://www.thefamilypickers.com/mock-home/

This is our free support forum. Replies can take several days. If you need fast email support, please purchase a SiteOrigin Premium license.

  1. 9 years, 2 months ago Magus
    Hi, I Work Here

    Hi Kristin

    Please add the following to Appearance->Custom CSS

    @media all and(max-width:480px){
    #panel-w55af009d28745-0-0-0 .textwidget p {
        text-align: center !important;
    }
    }
    

    This will only affect the text in that widget. Please be aware that the widget ID may change when you update the page.

    Let us know how you get on

    Magus

  2. 9 years, 2 months ago Kristin Gintert

    Thanks Magus,

    This is exactly what I wanted and works perfectly!

    Kristin

  3. 9 years, 2 months ago Magus
    Hi, I Work Here

    Glad to hear it. Let us know if you need any more help

    Magus

  4. 9 years, 2 months ago Kristin Gintert

    Can you please direct me as to how to find the widget ID? It worked when I put your code in but then I updated the page and it stopped working like you said it might. I thought I found the new ID but I can’t get it to work now so I must have the wrong thing. You’re help is appreciated :-)

    Kristin

  5. 9 years, 2 months ago Kristin Gintert

    LOL never mind… I figured it out. I forgot to put a space after the widget ID… its working now :-)

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.

Get The Most Out of SiteOrigin with SiteOrigin Premium

Find Out More