Accessing bound user contact details
If you need to access information about the currently logged-in user in PHP. It can be easily done by using UserService class that has methods to return the current user information including the linked CRM record (if available).
Accessing Choice columns metadata
When custom forms include a choice column (previously known as an optionset or a picklist), access to the metadata is required to include all possible values as part of the markup, usually as a SELECT HTML tag.
Add current WordPress user to Twig
To add WordPress user as an object to Twig, use the following code:
Add custom functions and variables to Twig
To add a custom function use following filter:
Add Twig in header/footer
To inject dynamic data outside of the page content, you can use direct code in header.php or footer.php to render the dynamic content:
Adding a Registration - Handling 403 Errors
When adding a registration, you may encounter a 403 error. This typically occurs if your app user hasn’t been added to the security profile.
Check if email already exists in WordPress
Add a custom Twig function to verify if user with given email already exists.
Clearing the Cache
Cache Tab
Client secret has expired
Your client secret can expire. In that case, you need to create a new client secret See more details
Controlling Twig Access with ICDS_TWIG_USE_PRIVILEGES
The ICDSTWIGUSE_PRIVILEGES flag is designed to enhance security and editorial control over pages that utilize Twig-based integrations with Dataverse, including elements like ` and `.
Custom entity binding
Entity binding provides quick and easy way to associate a page with a specific row in a Dataverse table. Row id can be passed as a parameter or an alternate key can be used out of the box. For example, if we define an alternate key called Account Number for an account table that uses accountnumber column then we can configure account page binding as following:
Editing user profile
If a page is bound to a contact table then passing contact identifier in the query string will set the binding object and allow record editing using, for example, a Gravity form that relies on the record binding.
Enabling Detailed Error Display in Browser Console for Forms
When working with premium or custom forms in DataPress, rendering issues may occur due to misconfigurations or JavaScript errors. To assist with debugging, you can enable more detailed error output in your browser’s developer console.
How to bind a user using WP API
All API requests below require Basic Authentication.
How to combine values from multiple Gravity Forms fields into one other column
If you need to combine values from multiple Gravity Forms fields into one other column, follow these steps:
How to display a list of bound users in WordPress
Here is a description of our metadata for a WordPress user record.
How to retrieve Dataverse records using Web API twig functions
Follow this example to retrieve multiple records:
Manage users
Overview
Syntax highlighting
We use Monaco Editor for syntax highlighting.
Unable to save connection settings
When connecting WordPress instance to Dataverse/CDS, you need to verify and then save the connection configuration.
Using lookups in the free plugin version
In this example, we create a form based on an account table with a lookup field from the contact table. This allow users to choose an account and a corresponding contact. To filter contacts, you can update the fetchxml part based on your specific requirements:
Using lookups in the premium plugin version
Use next steps to manage lookup fields in your forms:
WordPress Users Table
Introduction