BUG: ticket_end_date gets wrong time (1970-01-01)
-
Hi!
I have the following problem:
1) I create a new event.
2) I add a new ticket to that event.
3) I set a end date, when one can no longer buy tickets (e.g. ticket_end_date). I don’t set end hour but rather leave it as default, which is ’17’, because I live in an area where we use 24 hour clock.
4) I save the ticket and see the end date of ticket and it is 1970-01-01I have done some research on this issue and noticed that it happens because I can set hours greater than 12 but there is still am/pm setting available. When clicking Save ticket -button, ticket_add() function in file Tickets.php will be executed. This function in row 573 tries to create strtotime() of string that might not be valid time. For example ‘2018-03-03 17:00:00pm’. This why $ticket->end_date will be ‘1970-01-01 12:00:00am’
- The topic ‘BUG: ticket_end_date gets wrong time (1970-01-01)’ is closed to new replies.