Problem: I would like to know what parameters are available for use with the PHP API types_render_usermeta.
Solution:
The values in this array should correspond to the attributes available for each type of field. Those are listed in the documentation here:
https://toolset.com/documentation/customizing-sites-using-php/functions/
For example, check the Address field information. There are two attributes that apply to all Address fields: output and format. Now click the orange "+More" button to reveal some additional information specific to User fields. Next to "attributes (user)" you will find information about 4 other attributes that can be used with User Address fields. You can use one of these attributes to define which User will be queried. Beneath this area, you will find a PHP example showing the syntax:
types_render_usermeta( "user-address", array( "user_current" => true )
You can add the other attributes you want to include in the array, and get information from another User like this:
types_render_usermeta( "user-address", array( "user_id" => 12345, "output" => "raw" ) )
Relevant Documentation:
https://toolset.com/documentation/customizing-sites-using-php/functions/
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.
No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.
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 2 Antworten, has 2 Stimmen.
Last updated by viktorI vor 6 Jahre, 2 Monate.
Assisted by: Christian Cox.