Skip Navigation

[Resolved] Custom field value change automatically

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
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9: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/Hong_Kong (GMT+08:00)

This topic contains 2 replies, has 2 voices.

Last updated by fahimS-2 1 year, 11 months ago.

Assisted by: Luo Yang.

Author
Posts
#2563081

Tell us what you are trying to do?
I have 2 custom post types called Text & Video and I assigned a custom field group to both of the custom post types. Now in the custom field group there is a custom field called 'Best'.

Text and Video both post types will have some posts. And One of the posts of Text post type will be best.
For Video post type, one of the Video posts will be best. Now In the custom field 'Best', I want to hold the Best post link.

All of the text posts will have the same best post link in the 'Best' custom field. And all of the video posts, will have the same best post link in its custom field 'Best'.

Now if I need to change the 'best' custom field value in text posts, I will have to edit all the Text posts one by one. And the same goes for the Video posts.

How can I change the value from all the posts at once?

#2563587

Hello,

There isn't such kind of built-in feature as your request within Toolset or WordPress: Edit fields of multiple posts at once.

In my opinion, you can add a custom checkbox field "It-is-best" into both post types:
- Text
- Video

edit one of above post, setup the field "It-is-best" field value

In single Text post, display a post view:
- Query Video posts
- Filter "It-is-best" field
- In view's loop, display Video post information

So you just need to edit two Videos, to switch the best Video post

#2563805

My issue is resolved now. Thank you!