Skip Navigation

[Gelöst] Time Stamp to normal date

This support ticket is created vor 7 Jahren, 1 Monat. 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.

Heute stehen keine Supporter zur Arbeit im Werkzeugsatz-Forum zur Verfügung. Sie können gern Tickets erstellen, die wir bearbeiten werden, sobald wir online sind. Vielen Dank für Ihr Verständnis.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

Dieses Thema enthält 5 Antworten, hat 2 Stimmen.

Zuletzt aktualisiert von Minesh vor 7 Jahren, 1 Monat.

Assistiert von: Minesh.

Author
Artikel
#582714

Hi Minesh,
to your topic https://toolset.com/forums/topic/formatting-dates-correctly-on-import/#post-582018

I have the same issue, importing orders from a csv file. I have some custom fields in 'orders' and two of them are dates.
When i import, i see either nothing or some 1970 date, as other users have commented.

I think that topic of yours above is the most current follow-up on this issue. I added the code in functions.php but i can't figure out where those shortcodes could be placed relevantly. Not in the csv, not in the custom fields, not on the admin orders pages... Any tips?

/wp-admin/admin.php?page=wpcf-edit&group_id=401
result: /wp-admin/post.php?post=1099&action=edit

Thanks a lot!
Kind regards

#582725

Minesh
Supporter

Sprachen: Englisch (English )

Zeitzone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

Well - first of all, based on the debug information you shared with me I see that you are using outdated Toolset plugins. We always recommend to run with latest Toolset plugins.

Could you please update ALL Toolset plugins to it's latest official released version. You can download it from your account's download page:
=> https://toolset.com/account/downloads/

Now, regarding the date issue you shared, I checked in your database and I see that date is not correctly stored. See the screenshot:
=> versteckter Link

Could you please make sure that your date field is stored as Unix timestamp.

#582757

Hi Minesh, Views plugin is updated now.

"regarding the date issue you shared, I checked in your database and I see that date is not correctly stored. "
--> I'm still a week with our programmer on holidays, what i need to do here? I guess they're stored as the plugin wants them to store? Aren't they stored in Timestamp by default (at least that's what i understood formt the other topics on this subject)?

PS important: whatever you do, please DO NOT change the theme
Thank you!

#582761

Minesh
Supporter

Sprachen: Englisch (English )

Zeitzone: Asia/Kolkata (GMT+05:30)

PS important: whatever you do, please DO NOT change the theme
==> I'm not doing any changes.

"regarding the date issue you shared, I checked in your database and I see that date is not correctly stored. "
--> I'm still a week with our programmer on holidays, what i need to do here? I guess they're stored as the plugin wants them to store? Aren't they stored in Timestamp by default (at least that's what i understood formt the other topics on this subject)?
===> Well - as you can see the field value is "43042" and that is not timestamp. Please make sure that when you import date field the field value should be imported as unix timestamp.

You can try to convert date to timestamp using follwoing link for test purpose to know equivalent date timestamp.
More info:
=> versteckter Link

#582806

so we need to convert whatever 'date' is stored, to a timestamp and then back to a date? Hmmm 🙂
I think that after spending already over half a day with this issue, I mark it as 'impossible' and use normal text field instead. That's not very user-friendly when so many people are wrestling with this problem...

Thanks!

#583177

Minesh
Supporter

Sprachen: Englisch (English )

Zeitzone: Asia/Kolkata (GMT+05:30)

so we need to convert whatever 'date' is stored, to a timestamp and then back to a date?
==> Yes - you need to make sure that the value stored in Types date field must be stored as timestamp.