Skip Navigation

[Resolved] Archive Date Format Not Correct

This thread is resolved. Here is a description of the problem and solution.

Problem:
Fields displayed with types_render_field() don’t work with Date and Skype fields and also they have issues with show_name attribute

Solution:
https://toolset.com/errata/types-fields-are-not-displayed-properly-using-types_render_field/

This support ticket is created 6 years, 4 months 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.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

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)

Tagged: 

This topic contains 5 replies, has 2 voices.

Last updated by elizabethC-2 6 years, 4 months ago.

Assisted by: Beda.

Author
Posts
#954758
Screen Shot 2018-07-24 at 5.26.09 PM.png

Hi!
On the archive page of some job listings, the job closing date is now not formatted correctly. It was correct fairly recently, I'm not exactly sure when it changed. It is now formatted like this: 1542153600.

This is the archive page link: hidden link

This is currently how I have it in the template for the view:
<td>[wpv-post-link]</td>
<td>[types field='location'][/types], [types field='state'][/types]</td>
<td>[types field='type' separator=' '][/types]</td>
<td>[types field='listing-closing-date'][/types]</td>

Any idea what I need to do? Thank you!
Elizabeth

#955378

I think it is the same source issue as here:
https://toolset.com/forums/topic/types_render_field-format-is-not-working-for-date-fields/

But I cannot confirm that issue.
I used this:

[types field='date' style='text' format='j F Y'][/types]

And as well [types field='date'][/types], and others.

If I use types_render_field (the function) I see that there are errors when I do not pass either format or style.
Then, there is a PHP error on the page where I display the field:

Notice: Undefined index: style in .../types/application/models/view/decorator/calendar.php on line 17

(same for format)

That could be the same issue here.

Do you see that same error?

if not, this may be something with how the field was saved in a previous version.
In that case I'll probably need a copy of your site to replicate this:
https://toolset.com/faq/provide-supporters-copy-site/

#955398

I think we managed to replicate and it's now with the developers.

#956357

This will be solved in Types 3.0.7

#956379
#956637

Thank you!