Skip Navigation

[Resolved] Post field displaying code instead of date

This support ticket is created 7 years, 1 month ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- - 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00
- - - - - - -

Supporter timezone: Asia/Ho_Chi_Minh (GMT+07:00)

This topic contains 1 reply, has 2 voices.

Last updated by Beda 7 years, 1 month ago.

Assisted by: Beda.

Author
Posts
#582810
date-error.PNG
date.PNG

I am using the Visual Composer and Grid Builder to create Grid Views of Types custom post types. If it´s a single line or a url, it is displaying the information correctly (using the wpcf prefix). However if I want to display a date it's showing some strange data (I guess this is kind of a raw data). Is there a fix for this?

#582928

This is a Timestamp you see there, and that is what the Date Field stores in the Database when you save a new Date.

To render a valid date certain PHP Functions need too be run, and Visual Composer or other 3rd Party Plugins do not know that this is a Date field stored as a Timestamp - the same problem happens often with 3rd Party Fields that cannot be rendered fine with Toolset.

Now, what you can do is use our own ShortCode to display that Field (you can insert our ShortCodes almost anywhere in a Text Editor, also page builders), or you need to create a Custom Code which re-calculates the Timestamp to a readable Date:
hidden link

It is not possible to tell Visual Composer how to render this field - the composer just renders the Raw data, and this it does very well, as it seems.