Jordan Posted August 29, 2007 Share Posted August 29, 2007 I've been configuring some pages to be set up so that a user needs to be logged in, however the text that is displayed when a user is not logged in, is still displayed when a user IS logged in. What statements would I use for the content that should ONLY be displayed when I user is NOT logged in? =) 0 Quote Link to comment Share on other sites More sharing options...
Boss Posted August 29, 2007 Share Posted August 29, 2007 I've been configuring some pages to be set up so that a user needs to be logged in, however the text that is displayed when a user is not logged in, is still displayed when a user IS logged in. What statements would I use for the content that should ONLY be displayed when I user is NOT logged in? =) {if !$loggedin} Item you don't want displayed [u]when[/u] logged in {/if} {if $loggedin} Item you don't want displayed [u]unless[/u] logged in {/if} 0 Quote Link to comment Share on other sites More sharing options...
Jordan Posted August 29, 2007 Author Share Posted August 29, 2007 Thanks I'll try that out. 0 Quote Link to comment Share on other sites More sharing options...
domainworldaccess Posted September 7, 2007 Share Posted September 7, 2007 Does this work outside the WHMCS directory? So if I have pages at mydomain.tld and WHMCS is at mydomain.tld/WHMCS, is there anything I need to add to the listed code for WHMCS to know whether or not a user is logged in outside of the WHMCS directory? 0 Quote Link to comment Share on other sites More sharing options...
WHMCS CEO Matt Posted September 7, 2007 WHMCS CEO Share Posted September 7, 2007 This code will only work in the WHMCS template files. Matt 0 Quote Link to comment Share on other sites More sharing options...
trine Posted September 7, 2007 Share Posted September 7, 2007 Does this work outside the WHMCS directory? So if I have pages at mydomain.tld and WHMCS is at mydomain.tld/WHMCS, is there anything I need to add to the listed code for WHMCS to know whether or not a user is logged in outside of the WHMCS directory? You would need to test for a valid whmcs session and if they are logged in using php instead. 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.