Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
By default Drupal behaviour, it uses C.E. year but my country (Thailand) uses B.E year (+543). I have added thai.class.inc.php for my country that year will add by 543. That class hasn't finish yet.
When node save at first, it works fine because node author date is empty. Drupal will add automatically but when node is editing, node author date will be C.E. year that make the wrong timestamp.
Ex.
First time: 2011-07-27 11:00:00 +0000
Editing: 2554-07-27 11:00:00 +0000
I think we have to use hook_nodeapi() with operation presave. Anyone has any ideas?
Comment | File | Size | Author |
---|---|---|---|
calendar_system_patch_thai.patch | 1.8 KB | rutcreate | |
Comments
Comment #1
sinasalek CreditAttribution: sinasalek commentedMarked
Comment #2
sinasalek CreditAttribution: sinasalek commentedThanks @rutcreate, i was about to include your patch in the news release but the patch does not contain your thai plugin
Comment #3
sinasalek CreditAttribution: sinasalek commentedThere is another issue address the node save and validation issue #1135072: implementing Date Validation for different calendar systems
Comment #4
sinasalek CreditAttribution: sinasalek commentedComment #5
sinasalek CreditAttribution: sinasalek commentedWe have the patch here #1878628: Calendar system for Thai
change the status to need review
Comment #6
sinasalek CreditAttribution: sinasalek commentedCommited to 7-x.1.x and 6.x-1.x