Skip Navigation

[Resolved] SHowinf different content to non registered user

This thread is resolved. Here is a description of the problem and solution.

Problem:
I need to display different content to logged-out users on the create memorial form, instructing them to create an account first.

Solution:
Use Toolset’s conditional blocks to hide the form from logged-out users and display a custom message instructing them to create an account. Set the criteria to target users with an empty Current User ID.

Use this criteria:

Current User ID > Empty Value

conditional

Relevant Documentation:

https://toolset.com/course-lesson/using-toolset-conditional-block/

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 4 replies, has 2 voices.

Last updated by JacquesF783 1 year, 1 month ago.

Assisted by: Christopher Amirian.

Author
Posts
#2647535

Hello,

On the create memorial form.
How can I show different content to logged out user?

I want to say something like : "in order to create a memorial you need to create an account first"

Thanks

#2647799

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

The first step will be to use the Toolset Access control to hide the form for logged out users. For more information:

https://toolset.com/course-lesson/controlling-access-to-front-end-forms/

After that, you can add the shortcode below in a normal Paragraph block or a shortcode block in the block editor to show a message for the logged out users:

Old code retrated, use the next answer for the conditional blocks

Feel free to change the text inside the shortcode to accommodate your use-case.

Thanks.

#2647833

Thanks it works,

Can I do that with conditional block as well?

Jacques

#2647909

Christopher Amirian
Supporter

Languages: English (English )

Screenshot 2023-09-27 at 14.47.02.png

Hi Jacques,

Actually, it is better to use conditional blocks.

Use the conditional block:

https://toolset.com/course-lesson/using-toolset-conditional-block/

And set the criteria as:

Current User ID > Empty Value (check the screenshot)

That way you will target the logged out users, and now inside the conditional block you can add whatever content and blocks you want for the message.

Thanks.

#2648187

That worked thanks,

By the way please,

How do I view all my historical tickets that I created?

Thanks

Jacques

#2648189

I found out how I can view all my tickets. Thanks for your assistance on this ticket.

Jacques