So there are a bunch of elements on the page but i need to show different elements to different users, so I want the page code to identify the user first, and then show only the needed elements.
Hello! Can you add a little more information to this so anyone who sees the post can help you better.
What data is connected to the user that you want to use as a filter? And where is this information currently stored in your data structure.
For example, if you are using user roles, you can get the logged in user role and then decide what to show hide on a page based on the role.