Skip Navigation

[Resolved] Calculation and store with custom fields

This support ticket is created 4 years, 10 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
- 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)

Tagged: 

This topic contains 3 replies, has 2 voices.

Last updated by Minesh 4 years, 10 months ago.

Assisted by: Minesh.

Author
Posts
#1276499

Dear Toolset support team,

We need to calculate some numbers from specific custom fields and then STORE the calculated results in other custom fields.
The result part is our problem, we know how to do calculations and show them in front end, but we are a little confused about storing and recalling the stored data later.
Also, please help us realize, is it possible to do all this between separate custom post types with several custom fields.

Thank you,
Hamid Moghaddasi

#1276545

Minesh
Supporter

Languages: English (English )

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

Hello. Thank you for contacting the Toolset support.

The result part is our problem, we know how to do calculations and show them in front end, but we are a little confused about storing and recalling the stored data later.
==> Can you please share more details. normally, If you have custom field that is used to store the result of the calculation later you can use this result field for sorting.

Also, please help us realize, is it possible to do all this between separate custom post types with several custom fields.
=> Do you mean that you want to use same result field with different post types?

#1276547

I need assistance for storing the calculated results? This is we don't know.
How exactly can we save a calculation result in custom field?

#1276551

Minesh
Supporter

Languages: English (English )

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

I would like to know first when exactly you want to save the result of a calculation - is it while saving the post? If yes:
- You can use the standard save_post action hook as described with the following Doc:
=> https://toolset.com/documentation/customizing-sites-using-php/updating-types-fields-using-php/

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.