Skip Navigation

Populate a Cred field with data linked to the type

This support ticket is created hace 8 años, 5 meses. 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.

This topic contains 3 respuestas, has 2 mensajes.

Last updated by Adriano hace 8 años, 5 meses.

Assigned support staff: Adriano.




Is it possible in a Cred form, to affect a specific value to a field that is already created?
For example, I have a type (Event) in which I have integrated a Cref form (Concours). I would like that a single ligne field (Nom) of this Cred form returns the Event's name. What's the best way to do this?


Dear Pat,

You will need two things to achieve that. A generic field to store these values and a view to populate it.

Your generic field should looks like:

[cred_generic_field field="teste" type="text" class="" urlparam=""]
"options":[ [wpv-view name="Test New"] ]

Then you need to create a view with the correct filter you want, the output format should be like that:

<wpv-loop>[wpv-item index=1]{"value":"[wpv-post-title]","label":"[wpv-post-title]"}[wpv-item index=other],{"value":"[wpv-post-title]","label":"[wpv-post-title]"}</wpv-loop>

Please let me know if you are satisfied with my answer and if I can help you with any other questions you might have.



Thanks Adriano


You are welcome.