Jump to content

Trying to block content from certain clients - Need help


peeta

Recommended Posts

I need to block some content in the client area from a few clients when they login and I tried using the client ID tags below but neither worked.

 

{if client_id == '100'}show this{else}show this{/if}

also tried

{if $clientsdetails.id == '100'}show this{else}show this{/if}

 

Can some one point me to the correct tag or method to achieve this? Thanks

Link to comment
Share on other sites

Sparky I get an error with that method

 

Fatal error: Smarty error: [in newtmp/header.tpl line 71]: syntax error: unidentified token '['uid']' (Smarty_Compiler.class.php, line 1396) in /home/hosting/public_html/libs/Smarty.class.php on line 1095

 

I even tried it without the quotes and got the same error

Link to comment
Share on other sites

Well I'm a goose... thats a php variable...

this will work but only on certain pages where clientsdetails variable is available

{if $clientsdetails.id == '100'}show this{else}show this{/if}

to get it for any page

{php}$this->assign('gothim',$_SESSION['uid']);{/php}

{if $gothim == '100'}show this{else}show this{/if}

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated