PDA

View Full Version : User Rank Multiple Image Help


Soholaunch
05-03-2004, 05:27 PM
I am trying to make it so that I can use 2 images for a user rank, but am unsure how. This is what I would like the rank to look like.
http://cam.soholaunch.com/images/Guru-ss.gif
The /sohoadmin picture is the picture currently displayed with that usergroup, but I would also like to add the Guru picture which is seen on the right side to display how it is shown in the above picture. Could someone help me out with how to do this?

Tony G
05-04-2004, 07:50 AM
I think you could just create a new user field, disable it's change through the User CP and just use the ACP's profile options to add the URL of the image. Then put the variable in the postbit.

I'll get back to you on this.. I'm not sure if you can turn newly created profile fields off so people can't change them in the User CP. Just in a bit of a rush here. One of the other mods could answer you on this.

Soholaunch
05-04-2004, 02:32 PM
I got a similar response from someone in the vbulletin.org chat room, but unfortunatley he was short on time and I didn't get a very good explanation on how to accomplish this.

After I add a new user field how do I disable it, and how do I add it to the post bit?

=/ Still kinda new here.

Tony G
05-05-2004, 05:18 AM
Okay, here's how to do it.

When creating the new field, make sure you don't allow it to be edited in the User CP (Edit profile) and hide it from users.

Now, take note of the field number of the newly created profile field.

Now open postbit/postbit_legacy (whatever your setting is) and add where you want it:

<if condition="$post['fieldX']"><img src="$post[fieldX]" alt="" /></if>

Now, replace X with the field number of your newly created field. Next, go into the profile and where you see the field for your new profile field, add the URL of the image. Should work. Not tested.

(You can also do this with stylevars to make your life easier, so if you want that, just reply saying so)