How can you adjust the width of the date/time field?

  • mojo30
    Asked on March 13, 2016 at 8:41 AM

    I'm using the date/time field on my forms in "lite" mode.  (i.e. MM/DD/YY all in same field).  The problem I'm having is that when viewed in a mobile device, the field appears to only be 2 characters wide.  It needs to be 8 characters wide.  Is there a way to adjust it?  Or can you fix it on you end?

    Thanks much!

     

  • jonathan
    Replied on March 13, 2016 at 8:52 AM

    Was it this Date field?

    How can you adjust the width of the date/time field? Image 1 Screenshot 20

     

    You can add custom CSS code llke this to your form http://www.jotform.us/form/53246589667169

     

    #lite_mode_4 {

    width : 100px;

    }

     

    Adjust the px number according to your preference. Let us know if this did not work.

    Thanks.

  • mojo30
    Replied on March 13, 2016 at 9:20 AM

    Thanks for the quick response!  Yes, this idea might work, if we didn't have the date picker immediately to the right.  If I do what you say, it does work for the text field, but then the picker shows overlapping the text field, because the picker doesn't move over.  Any thoughts on what CSS element I'd need to adjust width on to move the picker?

  • jonathan
    Replied on March 13, 2016 at 9:30 AM

    I see the problem when in mobile browser view

    How can you adjust the width of the date/time field? Image 1 Screenshot 20

    Let me check for a fix. I'll get back to you shortly.

  • jonathan
    Replied on March 13, 2016 at 9:41 AM

    This is my test form https://www.jotform.com/60723537237961 

    Please try it also on your browser.

    How can you adjust the width of the date/time field? Image 1 Screenshot 30

     

    I added this CSS codes

     

    #lite_mode_4 {

        width : 90px !important;

    }

    #cid_4 span.form-sub-label-container {

        width : 90px !important;

    }

     

    And I used Mobile Responsive widget 

    How can you adjust the width of the date/time field? Image 2 Screenshot 41

     

    Hope this help. Let us know if still not resolved.

    Thank you.

  • mojo30
    Replied on March 13, 2016 at 9:49 AM

    Excellent!  Not sure why that works, but it does.  Thanks a ton.  :)