I got some of it working now
This works
Code:
<vb:if condition="$vbulletin->options['bbr_playlist_active']">
<vb:if condition="$userinfo['field5']">
Show This in profile
</vb:if>
</vb:if>
But I need it to work like this because on different forums it will be a different field set in the options.
This does not work.
Code:
<vb:if condition="$vbulletin->options['bbr_playlist_active']">
<vb:if condition="$userinfo['{vb:raw bbrfield1}']">
Show This in profile
</vb:if>
</vb:if>
This does not work either.
Code:
<vb:if condition="$vbulletin->options['bbr_playlist_active']">
<vb:if condition="$userinfo['$bbrfield1']">
Show This in profile
</vb:if>
</vb:if>
Here is my plugin:
Code:
if ($vbulletin->options['bbr_playlist_active']){
$bbrplayergroups = explode(',',$vbulletin->options['bbr_playlist_user_groups']);
if (is_member_of($vbulletin->userinfo,$bbrplayergroups)){
$bbrfield1 = $vbulletin->options['bbr_playlist_profile_field1'];
$bbrfield2 = $vbulletin->options['bbr_playlist_profile_field2'];
$bbrfield3 = $vbulletin->options['bbr_playlist_profile_field3'];
$templater = vB_Template::create('memberinfo_block_playlist');
$templater->register('bbrfield1', $bbrfield1);
$templater->register('bbrfield2', $bbrfield2);
$templater->register('bbrfield3', $bbrfield3);
$templater->register('userinfo', $userinfo);
$template_hook['profile_right_first'] .= $templater->render();
}
}