Skip Navigation

[Closed] Using Toolset custom fields with Yootheme Pro 2.0 'Dynamic Content'

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

Sun Mon Tue Wed Thu Fri Sat
- 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 -
- 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 -

Supporter timezone: Europe/London (GMT+00:00)

This topic contains 1 reply, has 2 voices.

Last updated by Nigel 4 years, 8 months ago.

Assisted by: Nigel.

Author
Posts
#1593459

Tell us what you are trying to do?
Yootheme have recently released the new version 2.0 for their framework 'Yootheme Pro' (hidden link).

The main feature of this release, is that it has a feature called 'Dynamic Content', in other words, the Yootheme Pro Page Builder can now allow you to dynamically load in content from your worpress posts, pages and custom post types.

So far, it seems that however, there is a slight issue regarding its compatibility with toolset, I will explain:

- Custom Post TYPES created with Toolset, DO load into Yoothemes 'Dynamic Content'. All good so far (this is achieved by making sure the CPT 'Rest Base' field is populated with the CPT 'Plural' value.
- Custom TAXONOMIES created with Toolset, also DO load into dynamic content. Great 🙂
- However, and this is the problem, it seems that Custom FIELDS created with Toolset, do NOT appear in dynamic content. For some reason it does not pick them up.

So I have been asking around to try and find what the problem is, and today on the Yootheme support forum, somebody has told me the following:

"The custom rest api slug has to be enabled and it must be PLURAL for it to work. Tested with Pods and ACF. "

So, I have tried to look in Toolset, but within my custom field I cannot see a custom field rest API slug, so I don't really understand what this means? I have tried enabling the Toolset > Settings > Custom Content > REST API field, but that did not fix the problem. I also tried looking at this article in your knowledge base = https://toolset.com/documentation/programmer-reference/toolset-integration-with-the-rest-api/ but to be honest, I don't really understand this page, or if this page is telling me something I need to do, which I have missed?

Please can you provide any help as to why Custom Fields created by Toolset are not showing (even though CPT and CT are showing)? And what I need to do within Toolset to fix this?

Thank you very much in advance for your help 🙂

Keith

Is there any documentation that you are following?
Toolset = https://toolset.com/documentation/programmer-reference/toolset-integration-with-the-rest-api/
Yootheme = hidden link

Is there a similar example that we can see?
No

What is the link to your site?

#1593735

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

Hi Keith

I took a look at the final link you shared, the yoothemes documentation, and it doesn't give any details about what specifically is required for custom field support.

From the documentation it looks like they have explicitly built compatibility with ACF.

Custom fields, whether they are made with Pods, or ACF, or Types are all stored in the wp_postmeta table, and for simple text and numeric fields you would be hard pressed to spot the difference looking at that table.

Things get slightly different with more complex fields in terms of translating how the values are stored into the values output on the page, but for most fields the raw value is stored as a simple string and should be readily accessible.

Limiting ourselves to simple text fields for the moment, there is no difference between how ACF or Pods or Types or—crucially—native WordPress itself store custom fields.

Toolset has a bespoke REST API layer for accessing its custom fields, but that is for retrieving the formatted values, e.g. returning a URL as a link tag instead of just a plain text URL, and the raw values can be returned using the standard WordPress REST API routes and endpoints.

So, you need to ask Yootheme support whether native WordPress custom fields are supported by its dynamic content, and if so how are they accessed.

If they are then you will be able to use the same to access Types custom fields, but only the raw values as stored in the database rather than the formatted values you would normally output in Toolset templates with shortcodes (or, now, using blocks).

The only detail about Types fields you would then need to know is that they are stored in wp_postmeta with a wpcf- prefix, e.g. a custom field with a slug of 'status' would be stored with a key of 'wpcf-status'.

Let me know what they say.

The topic ‘[Closed] Using Toolset custom fields with Yootheme Pro 2.0 'Dynamic Content'’ is closed to new replies.