The Arcive of vBulletin Modifications Site. | 
    |
| 
		 
			 
			#1  
			
			
			
			
			
		 
		
	 | 
|||
		
		
  | 
|||
| 
		
	
		
		
			
			 
			
			I'm trying to make something on my siite disabled based on a profile option? I hard coded the item into the theme. 
		
		
		
		
		
		
		
		
	
	Also, is there a way to do this via which usergroup they are in?  | 
| 
		 
			 
			#2  
			
			
			
			
			
		 
		
	 | 
|||
		
		
  | 
|||
| 
		
	
		
		
			
			 
			
			I'm not sure what you mean by "hardcoded". If you're using templates, you should be able to put the code for the stuff you want disabled in an "if" tag, like: 
		
		
		
		
		
		
		
		
	
	Code: 
	<vb:if condition="$bbuserinfo[fieldX] == 'something'"> // code for feature </vb:if> or to do it by usergroup Code: 
	<vb:if condition="!is_member_of($bbuserinfo, X)"> // code for feature </vb:if> Of course you need to change the X's and 'something' to the appropriate values.  | 
| Благодарность от: | ||
| Bomyne | ||
| 
		 
			 
			#3  
			
			
			
			
			
		 
		
	 | 
|||
		
		
  | 
|||
| 
		
	
		
		
			
			 
			
			Thanks. It works perfectly. 
		
		
		
		
		
		
		
		
	
	On a variation on the second code you gave, is there a way to add that to the postbit template to show a special image or title if the user is in this usergroup?  | 
| 
		 
			 
			#4  
			
			
			
			
			
		 
		
	 | 
|||
		
		
  | 
|||
| 
		
	
		
		
			
			 Quote: 
	
 Yes, just edit the postbit or postbit_legacy template and add something like: Code: 
	<vb:if condition="is_member_of($bbuserinfo, X)"> // code for image </vb:if> By the way, you can include more than one usergroup if you want, by listing the ids, like: Code: 
	<vb:if condition="is_member_of($bbuserinfo, 5, 6, 7)"> ...  | 
| 
		 
			 
			#5  
			
			
			
			
			
		 
		
	 | 
|||
		
		
  | 
|||
| 
		
	
		
		
			
			 Quote: 
	
 Basically what i've done is set up a supporter system. Those that donate have the ads disabled (Which is thanks to the second code block in the first post) now i want to add a badge to that users posts to aknowdge they are a supporter. The subscription system adds them to group 12.  | 
| 
		 
			 
			#6  
			
			
			
			
			
		 
		
	 | 
|||
		
		
  | 
|||
| 
		
	
		
		
			
			 
			
			Oh right, that would be the viewer. I should have realized if you wanted it in the postbit you probably wanted the poster. In that case just replace $bbuserinfo with $post. 
		
		
		
		
		
		
		
		
	
	Code: 
	<vb:if condition="is_member_of($post, X)"> // code for image </vb:if>  | 
| 
		 
			 
			#7  
			
			
			
			
			
		 
		
	 | 
|||
		
		
  | 
|||
| 
		
	
		
		
			
			 
			
			Thanks! Works great.
		 
		
		
		
		
		
		
		
		
	
	 | 
![]()  | 
	
	
		
  | 
	
		
  | 
| X vBulletin 3.8.12 by vBS Debug Information | |
|---|---|
						
  | 
				|
  More Information | 
				|
| 
						 Template Usage: 
						
 Phrase Groups Available: 
						
  | 
					
						 Included Files: 
						
 Hooks Called: 
						
  |