Navigation überspringen

[Gelöst] Update CPT Custom Fields via Rest API

Dieser Thread wurde gelöst. Hier ist eine Beschreibung des Problems und der Lösung.

Problem:

I am attempting to update a Custom Post Type's custom fields using the WP Rest API with the toolset-meta object, but I cannot find documentation on how to perform a PUT operation.

Solution:

The Toolset wrapper for custom fields does not support editing via the Rest API. Use native WordPress functions to access and update the custom fields, just like any other native WordPress field.

Relevant Documentation:

https://developer.wordpress.org/rest-api/

This support ticket is created vor 1 year, 9 months. 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.

Dieses Thema enthält 1 reply, hat 2 Stimmen.

Zuletzt aktualisiert von Christopher Amirian vor 1 year, 9 months.

Assistiert von: Christopher Amirian.

Author
Artikel
#2720099

I am attempting to update a CPT's custom fields using the WP Rest API and the toolset-meta object. I have not been able to find documentation on how to perform a PUT operation. Please advise.

#2720701

Christopher Amirian
Unterstützer

Sprachen: Englisch (English )

Hi there,

The Toolset wrapper for the custom fields does not support the edit functionality via Rest API.

You will need to use the native WordPress functions to access the fields and update them like any other native custom WordPress field.

Thanks.