Tet banner

Custom Fields
Support MB Custom Post Type How to Format Datetime in Oxygen Builder?

  • Creator
  • #29854
    Tobias Haas

    Dear MB Team,

    How can I change the format of the date?

    Standard is 2021-08-02
    i want: 02.08.2021

    I get the date from Dynamic Data in Oxygen


Viewing 4 replies - 1 through 4 (of 4 total)
  • Author
  • #29856
    Tobias Haas

    And how can I set the time to UTC + 1?

    Long Nguyen

    Hi Tobias,

    You can use the setting js_options to change the date format, such as

    'js_options' => [
        'dateFormat' => 'dd.mm.yy',

    If you are using the Builder, please use the option Date picker options https://imgur.com/8ip8rgD

    Get more details on the documentation https://docs.metabox.io/fields/date/#settings

    Tobias Haas

    Hi Long

    Your documentation would be much better if you showed a lot more examples.
    for me as a beginner it is a torture ...

    And how can I set the locale?
    I want to display the days in German language.

    thank you for your help 😉

    Long Nguyen


    To display the date in the German language, you need to follow these steps:
    - Set the site language in Admin dashboard > Settings > General > Site language: German
    - Set the timestamp to true
    - Use the function date_i18n() and follow the documentation to output the localization date.

    It might be complicated for the beginner but Meta Box is a developer tool, it helps you to output the raw value. So you need to have a basic knowledge of coding to display the value in any way you want.

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.