How to center a form on a mobile device

  • eroma
    Asked on September 20, 2016 at 12:27 AM

    I tried using the mobile response align center but on chrome in andorid my form is still aligned to the left.  Can you let me know what I have to do to resolve this?  Thanks!

     

     

  • Elton Support Team Lead
    Replied on September 20, 2016 at 2:00 AM

    The standalone form by default is centered on the page.

    In your form, there is a custom CSS code injected into it that changes its width to 'auto' when viewed on mobile. This what makes the form to shift on the left side.

    To center align the form back, inject this CSS codes to your form.

    @media only screen and (max-device-width: 550px){

    .form-all {max-width: 420px !important;}

    }

    Guide: https://www.jotform.com/help/117-How-to-Inject-Custom-CSS-Codes

    It should look like this afterward on mobile

    How to center a form on a mobile device Image 1 Screenshot 20

    Hope this helps!

  • eroma
    Replied on September 20, 2016 at 2:46 AM
    That worked perfectly. Thank you very much!!!

    Regards,
    Dwayne



    ...