Jump to:

11003 Posts in 2735 Topics by 1824 members

All other Modules

SilverStripe Forums » All other Modules » Userforms date validation not working

Discuss all other Modules here.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1 2
Go to End
Author Topic: 2528 Views
  • Liam
    Community Member
    470 Posts

    Re: Userforms date validation not working Link to this post

    Funny that about a year ago I was the last to post in this topic when I wasn't even having issues with the bug, and now I've come across it too.

    I'm using 3.1 and have the same issue as being reported here though it only happens when using IE7/8, all other browsers are fine.

    I had a DateField that was required. If a user picked the date with the calendar option in IE7/8 and submitted the form, the JS validation gave an error saying the field is required, even though it is filled in. I've changed the field to not required for an easy fix I thought, but the same error happens.

    I'll try deleting the field and readding it, as RuthAdele says that fixes the issue, but does anybody have a fix? I have about 10 forms with custom CSS layout this affects, so slightly annoying to go change them all.

    Here is the html source of the datefield being outputted. https://www.dropbox.com/s/kwn14mz9nvmmvxa/Screenshot%202013-11-18%2008.55.30.png

    The date is being filled in as yyyy-MM-dd and no matter what I put in i18n::set_date_format(); the format doesn't change.

    But like I said, works in all browsers except ie7/8, which I find really weird.

Page: 1 2
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.