WordPress.org

Forums

Custom Field Template
Diplaying date field in human readable format instead of timestamp (2 posts)

  1. kingsinger
    Member
    Posted 2 years ago #

    I created a custom type and some custom fields using the Easy Post Type Plug-in.
    One of them is type datefield.

    Now I am trying to display info from these fields in the loop of a custom type template I created. All of the fields display as expected except the datefield, which displays as a unix timestamp instead of in a human readable format.

    What do I need to do to make it display in human readable format? I'm not the biggest expert on WP or php. So please bear with me, if this is an obvious or stupid question. I just want the info to display in each post as something like mm/dd/yyyy.

    Here is what I've got entered in the template content for this field. I've added and taken away some these elements, but it hasn't changed anything.

    [date_cheese_sampled]
    type = datefield
    date = true
    dateFormat = yyyy/mm/dd
    size = 20
    Label = Date Sampled
    output=true
    format=0

    TIA,

    KS

  2. Arley McBlain
    Member
    Posted 1 year ago #

    Ever solve this?

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic