Navigation

Pligg Support

I'm trying to change the background color of the submitter on link_summary.tpl
but so far it's not working

I'm using this

{if $user_level eq 'admin'}
{$link_submitter}{else}{$link_submitter}
{/if}

Possible Answers

    Use this:

    **************************

    {if $user_extra_fields.user_level eq "admin"}

    Submitter is an Admin

    {elseif $user_extra_fields.user_level eq "moderator"}

    Submitter is a Moderator

    {elseif $user_extra_fields.user_level eq "normal"}

    Submitter is a Normal User

    {else}

    Probably Spammer

    {/if}

    ***********************

    http://pastebin.com/8FcufKmc

    | Posted 250 days ago | Permalink | Hide Replies

    You can simply use:

    {if $isadmin}

    code here......

    {/if}

    | Posted 250 days ago | Permalink | Hide Replies

    That will check if the user isadmin and show all admin features.

    I want to check the user_level of the user to display a different background color in the link_summary.tpl

    I want to do the same thing for moderators.

    | Posted 250 days ago | Permalink | Hide Replies

    This is the code I'm using.

    I'm not allowed to use html in the comments. so here goes pastebin

    http://pastebin.com/mUVme73G

    | Posted 250 days ago | Permalink | Hide Replies

Who Upvoted this Story