PDA

View Full Version : Check if user has permission to post in forum


addamroy
02-10-2013, 10:59 PM
I'm looking for a conditional to check if a user has permission to post in a certain forum.

My goal is to show a message to members where the 'post thread' button would be for users who don't have permission to post in a certain forum.

One of my forum's sections is a paid section for upgraded members only, and I'd like to show a 'you must upgrade your account to post here' message.

kh99
02-11-2013, 12:07 PM
You might be able to use $show['newthreadlink'].

addamroy
02-11-2013, 12:12 PM
That's what the template already uses. I'm using vb 4.1.12.

It says if condition shownewthreadlink I was thinking underneath that if statement I could add something, like an additional statement to would show the message I described.

Can I just add a ! to the condition like !$showthreadlink in an additional if statement underneath?

kh99
02-11-2013, 12:19 PM
Can I just add a ! to the condition like !$showthreadlink in an additional if statement underneath?

You could do that, or add an else to the condition, like:

<vb:if condition="$show['newthreadlink']">
Show Link
<vb:else />
Show message
</vb:if>




either way you get the same result.