The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
image display determined by user group status
We have vb setup with "premium" forum areas where only members of a certain "group" in vb have access. That part is pretty much a standard feature in vbulletin.
What I was hoping to accomplish is to have an image in my header that shows up if a person is not a member of that group in vbulletin, suggesting that they signup for that section. Once they have signed up it would switch to another graphic saying thankyou with a link attached to it describing the new features available to them. Has anyone done this type of mod before? Any help or files would be greatly appreciated. thanks in advance |
#2
|
||||
|
||||
Quote:
Replace X with the usergroup that is doating / paying |
#3
|
||||
|
||||
Quote:
The following template conditional expression contains function calls: <if condition="!is_member_of($bbuserinfo, 6)"> Function Name Usage in Expression is_member_of is_member_of($bbuserinfo, 6) With a few exceptions, function calls are not permitted in template conditional expressions. Please go back and re-write this expression. The following functions are allowed in template conditional expressions: in_array() is_array() is_numeric() isset() empty() defined() array() can_moderate() can_moderate_calendar() exec_switch_bg() I was putting that in the header template. ideas? |
#4
|
||||
|
||||
Quote:
<if condition="is_member_of($bbuserinfo, 6)"><else /> img code here instead </if> |
#5
|
||||
|
||||
Quote:
The following template conditional expression contains function calls: <if condition="is_member_of($bbuserinfo, 6)"> Function Name Usage in Expression is_member_of is_member_of($bbuserinfo, 6) With a few exceptions, function calls are not permitted in template conditional expressions. Please go back and re-write this expression. The following functions are allowed in template conditional expressions: in_array() is_array() is_numeric() isset() empty() defined() array() can_moderate() can_moderate_calendar() exec_switch_bg() is there maybe a place in vb that i am supposed to define what functions are allowed to be called? what is happening is when i input that code into my header, and click submit and reload, i get that error and it asks me to return to my header editor, with the new code allready taken out. |
#6
|
||||
|
||||
Quote:
|
#7
|
||||
|
||||
Quote:
here is exactly what i am inserting into the header template editor: <if condition="is_member_of($bbuserinfo, 6)"><else /><a href="url to file"><img src="url to my image"></a> </if> when i put that into the header area, and click submit, that's when i get the error.. it keeps kicking it out and won't allow me to input that anywhere. |
#8
|
||||
|
||||
is_member_of() cannot be called via templates. Try this instead:
HTML Code:
<if condition="$bbuserinfo[usergroupid]==6"><a href="url to file"><img src="url to my image"></a></if> |
#9
|
||||
|
||||
Quote:
thank you one thing i would like to change: the way this works as is shows a picture if you are in the admin group. What I want to do: if the person is a regular member and not a member of group 10 (superuser) I want the graphic to show up. Once the person is a member of group #10, then they would get another graphic. concept is it's a "banner" add that asks them to become a supporter, they get a banner to click that sends them to the page to become a supporter. Once they join, they then get a new banner with the link to their new areas of access. As a member can be a member of multiple groups at one time, such as group#2 (registered), and also be a superuser, i'm not sure how to write the code to have the group #10 membership over-ride the banner add, and only show the access banner. any help is appreciated, and many thank you's to the help allready provided. |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|