[TH] Date Field for Custom Fields (Custom Field XML) [Deleted]

Here is what the date field results in the output
View attachment 90474

Anyone able to make this add-on work??

I got this to insert the db by setting the Value Match Requirements: to None instead of using the Callback.

I got it to display in my thread by setting the
Value Display as:
  • Value Display HTML:
Edit thead defaults to 1970 so I still need to troubleshoot this. This field is still useful in understanding how a callback works. Thank you.

Chuck
 
I'm not familiar with php but here is an alternative way to solve the issue. In case someone like us still using 1.x Xenforo
1. Open library/Waindigo/CustomDate/CustomField.php
2. Delete the code below
Code:
        try {
            $value = unserialize($value);
        } catch (Exception $e) {
            $value = strtotime($value);
            return true;
        }
3. Save and have a try

I wonder this custom field is REQUIRED to pick up a date (not type in) so there is no chance to make it "wrong", so no need for "verifyDate". In case if you delete the correct date format, this field will not show up after save the post. No DATE data will be write to the database, sure there is no error log.
 
Top Bottom