You need to sign in to do that
Don't have an account?
EIE50
Login/ logout links
Hi,
I want to have a dynamic login / logout links in my header part, for example, if a guest user comes to the site/ portal, a login link should be visible, if a user login then a logout link should be visible instead of login, and vice-versa. How can this be done in the salesforce and any starting points for proceeding.
Thanks.
CloudDev
Assuming you're sharing the same Visualforce page between your unauthenticated Site and an authenticated portal, a simple approach would be to add some conditional logic in the controller (or controller extension) to test the profile of the user. If this equates to guest then it's sites and display Login and so on.. Ideally you want to be use a page template design or a component for this, so the code exists in one place only..