Only display certain content internally and other content externally

Hi,

We are currently making a template that would be used both by clients and people within our company. We would like to include links to certain accounts so that our colleagues could use these when working with information provided by clients, but we don’t want clients to have access to these links. Is there a possibility to only display certain content for people internally and display other content for people externally?

Kind regards,

Koenraad

Hi Koenraad,

Nice case, thanks for posting!

I’d suggest using a condition to filter on user email:

{% if user.email contains '@youroffice.com' %}
---content you wish to hide from outsiders---
{% endif %}

Best regards and good luck with coding!

Simon

Hi Simon,

Thank you for the quick reply.

This works perfectly!

Have a nice evening

Kind regards,

Koenraad