Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC:

Validation of date in search field 02 Oct 2012 06:55 #4208

  • Ferm
  • Ferm's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 39
  • Thank you received: 6
Not a big problem, but I noticed that if you drag a date field to a search box (or range in my case), and then enter an invalid date like '123' in the search filed, the application crashes with the following message (both in sandbox and locally):

500 - DateTime::__construct() [datetime.--construct]: Failed to parse time string (30-11-99) at position 7 (9): Unexpected character

I added code to set the date to null if the input is invalid but it owuld be great to have this in the JDom library.

Please Log in or Create an account to join the conversation.

Re: Validation of date in search field 02 Oct 2012 08:15 #4210

  • JoomGuy
  • JoomGuy's Avatar
  • Offline
  • Moderator
  • Moderator
  • Joomla Enthusiast, Lover of Cooking
  • Posts: 1115
  • Thank you received: 195
Not really an answer as such but, I suppose the the most desirable way of handling this would be if the range would adhere to the format of the field it is working with - i.e. in the case of a date/datetime field, providing the calendar type input. This would allow users to pick a date from the calendar.

Not quite sure how to go about modifying this as such but, I'm sure that there are some fellow cooks who could propose some files to change...

Anybody...?

Gez
Need help with your Cook/Joomla Project? . PM me to find out what I can help with. NO time wasters please!!!

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Time to create page: 0.057 seconds

Just wanted to congratulate you on the J-Cook website / web development tool. In a couple of visits I've had a play around with Cook and have to say I think it is fantastic.  I've played with a number of component builders in the past and yours is certainly looking like the best so far. I'd also like to help you spread the word - I'm really surprised more people aren't excited about this tool. Good luck with the project.
Dean

Get Started