dlcomplete
New Member
Description
This template modification will allow the user to select what they want shown in their own postbit via their control panel. This can be done with anything in your postbit (i.e. user title, avatar, rank, location, post count, join date, custom profile field(s), etc).
Screenshot
Check the attachments at the bottom of this post for an example.
Install
A) Admin CP > User Profile Fields > Add New User Profile Field
A.1) Choose Multiple-Selection Checkbox (you may use multiple-selection menu).
A.2) Put "Hidden Post Information" in Title (you may write whatever you want).
A.3) Put whatever you intend to have the option to hide in Options ("Avatar", "User Title", "Join Date", "*Custom profile field name*", etc). Remember the order they are in!
A.4) The rest is irrelevant. I suggest you give some kind of description so your members know what this is for. I would probably either put this on the "Edit Details" page or "Thread Viewing" section on the options page. You will probably want to hide this from your members list.
A.5) After you save, remember the the field ID. This will be in Name column. You will see "fieldx", 'x' being the ID number.
B) Styles & Templates > Style Manager > Edit Templates > Postbit Templates > postbit_legacy
B.1) Replace 'x' with the field ID and 'y' with the ID of the option.
The ID of the option is multiplied by two for each one. The first option on your list would be 1, the second would be 2, the third is 4, the fourth is 8, the fifth is 16, the sixth is 32, and so on.
B.2) In postbit_legacy, take the conditional you just made and post it before the conditional of the first option that you listed. I will use the avatar for my example.
Find:
Add above from what you have in step B.1:
Add below:
.3) Repeat this process on everything you made an option for. Remember to put in the right option ID in your conditional. The field ID will remain the same.
C) Done. Go into your control panel and choose what you want hidden from your posts.
This template modification will allow the user to select what they want shown in their own postbit via their control panel. This can be done with anything in your postbit (i.e. user title, avatar, rank, location, post count, join date, custom profile field(s), etc).
Screenshot
Check the attachments at the bottom of this post for an example.
Install
A) Admin CP > User Profile Fields > Add New User Profile Field
A.1) Choose Multiple-Selection Checkbox (you may use multiple-selection menu).
A.2) Put "Hidden Post Information" in Title (you may write whatever you want).
A.3) Put whatever you intend to have the option to hide in Options ("Avatar", "User Title", "Join Date", "*Custom profile field name*", etc). Remember the order they are in!
A.4) The rest is irrelevant. I suggest you give some kind of description so your members know what this is for. I would probably either put this on the "Edit Details" page or "Thread Viewing" section on the options page. You will probably want to hide this from your members list.
A.5) After you save, remember the the field ID. This will be in Name column. You will see "fieldx", 'x' being the ID number.
B) Styles & Templates > Style Manager > Edit Templates > Postbit Templates > postbit_legacy
B.1) Replace 'x' with the field ID and 'y' with the ID of the option.
PHP:
<if condition="!($post['fieldx'] & y)">
The ID of the option is multiplied by two for each one. The first option on your list would be 1, the second would be 2, the third is 4, the fourth is 8, the fifth is 16, the sixth is 32, and so on.
B.2) In postbit_legacy, take the conditional you just made and post it before the conditional of the first option that you listed. I will use the avatar for my example.
Find:
PHP:
<if condition="$show['avatar']">
<table align="center" cellpadding="6" cellspacing="0">
<tr>
<td valign="top"><div><a href="member.php?$session[sessionurl]u=$post[userid]"><img src="$post[avatarurl]" $post[avwidth] $post[avheight] alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a>
</div></td></tr></table>
</if>
Add above from what you have in step B.1:
PHP:
<if condition="!($post['fieldx'] & y)">
PHP:
</if>
.3) Repeat this process on everything you made an option for. Remember to put in the right option ID in your conditional. The field ID will remain the same.
C) Done. Go into your control panel and choose what you want hidden from your posts.