Problem: I have a generic field in a Form where Users can select from different post authors. It works fine in a new post Form, but in an edit post Form the select field does not display the selected value.
Solution: Use the wpv-post-author shortcode to pass the correct ID into the default attribute.
[cred_generic_field field='change_post_author' type='select' class='' urlparam=''] { "required":0, "validate_format":0, "default":[[wpv-post-author format='meta' meta='ID']], "options":[ [wpv-view name="Tutti gli Utenti"] ] } [/cred_generic_field]
Relevant Documentation:
https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-post-author
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 |
---|---|---|---|---|---|---|
8:00 – 12:00 | 8:00 – 12:00 | 8:00 – 12:00 | 8:00 – 12:00 | 8:00 – 12:00 | - | - |
13:00 – 17:00 | 13:00 – 17:00 | 13:00 – 17:00 | 13:00 – 17:00 | 13:00 – 17:00 | - | - |
Supporter timezone: America/New_York (GMT-04:00)
This topic contains 5 replies, has 2 voices.
Last updated by 6 years, 3 months ago.
Assisted by: Christian Cox.