The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Profile ReDesign - Add private fields?
I am redoing my memberinfo template. Started from scratch (but saved my original as this is my first time to do this with vb). Anyway I have the design and almost all info that I want all nice and sorted out. The only snag I am running into is instead of using the $customfields (because I want each field sorted out and placed elsewhere) I am placing each one (field) where they need to go. All the ones that are viewable to all (not private) are working like a charm. But I cannot get the private ones to work. So my question is how go I get my private fields to show to those who have permission to view them (such as me the admin) and be hidden from those not allowed to view them?
For example, I have one that is titled First Name with a field8 Running 3.6.7 PL1 Also the template_hooks that are in the original template. Do I need to add those to this? Honestly I am not even sure I understand that whole part. Thanks in advance for any help! |
#2
|
|||
|
|||
You should add the template hooks as they are needed for the upcoming official products and may be needed for some modifications.
To hide the private fields, you will need to wrap them in a conditional to stop users who are not in the usergroups that have permission to view them from seeing them. This will be in the form of <if condition="is_member_of($userinfo, x,y,z)"> where x,y,z are the usergroup id numbers of the groups you wish to be able to see the private fields. Apart from this conditional, the rest of the adding them is as normal. |
#3
|
|||
|
|||
Thanks I got the private fields covered doing exactly just that. I thought it was something like that but for the life of me could not remember (probably due to already working on it for 8 hours straight, lol).
About the template hooks, where should they be added or does it matter? For example $template_hook[memberinfo_pos1] that went right after the main info, avatar, profile pic, etc. comment in the default one. But now I have the avatar and profile pic completely split up as well as some of the other information. Is there any place that can tell me what template hook is for what item? So i know where to place them all? |
#4
|
||||
|
||||
Have a look at where they were originally placed. That will give you an idea of where to place them in your new template.
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|