In the thread of that ticket (Reply 2419653) Luo Yang confirms that was able to replicate the issue and that he would escalate it. After that, multiple workarounds are discussed in the remaining thread, before the ticket was closed as resolved. However, the only solution I can get to work is the custom function recommended by the user yonatanc in Reply #2428365.
I also tried another approach, which was to manually register [wpv-current-user] as a custom shortcode in Toolset Settings > Frontend Content, and then call that custom shortcode in the Conditional block, along with info="logged_in" as an attribute. Please see the attached screenshots.
In this way, I was able to save the condition without the wpv-current-user attribute reverting to info='id', but it's still not working on the front end as expected.
I can't find any way to make this work except with the custom function. That includes the suggested alternative condition (userID is empty).
Is there still an active work item (i.e., the escalation referenced by Luo Yang) in your product backlog and/or am missing something else?
Hello. Thank you for contacting the Toolset support.
The alternate method to this is you should use or compare the current user ID and check if its empty or not.
Please check the following screenshot:
- hidden link
With Luo's ticket which is reported to our internal system the solution shared by our next level support is to use and compare the current user ID instead of logged_in value.
I've attached several screen shots that show my attempt to configure the conditional using the UserID is (not) Empty argument, as well as the results on the front end, both when I'm logged in and when I'm logged out. None of the conditions seem to be triggering.
Can you please share problem URL where you configured your conditions as well as admin access details. Let me review whats going wrong with your setup.
I have set the next reply to private which means only you and I have access to it.
Toolset has limited integration with most of the Themes in your case you are using "Kadence" theme.
Also, Toolset is used to work with the the_content() area (post body). The widgets, header and footer is said to be managed by theme or possible theme integration with Toolset which is limited.
In your case I now recognize after reviewing your settings that you added the conditional statement with Widget area. So workaround is. I've created the following content template namely "Toolset Widget conditions" and added the conditional statement to this content template:
=> hidden link
As you can see I've added one condition that checks not empty with the above content template.
And then I've added that content template to your "Sidebar 2" (you can remove the conditions added to "Sidebar 2") and add whatever conditions you want to add to the content template "Toolset Widget conditions".
When I checked the page you shared: hidden link
I shows correct content I've added when current user ID is not empty (NOT EMPTY from CT).
Thanks so much. That did the trick. So, as a general rule, should I always use a template when trying to use conditionals (or other advanced blocks) in the theme widgets?