Log in

View Full Version : Image in Posbit Legacy Based On User Profile Field


Thamelas
01-18-2009, 12:17 PM
Maybe you guys can help me. I have vBulletin 3.7.4 Patch 1.

I am trying to make an image display in Postbit Legacy based on the users answer to a question in their profile, but I can't seem to get it to work. Can you guys tell me how to get this working?

Below is the code I have tried adding to the Postbit Legacy Template:


<if condition="$post['field11']"><div class="smallfont">$post<img src="/images/misc/[field11].gif" /></div></if>

Spank
01-18-2009, 01:17 PM
Maybe you guys can help me. I have vBulletin 3.7.4 Patch 1.

I am trying to make an image display in Postbit Legacy based on the users answer to a question in their profile, but I can't seem to get it to work. Can you guys tell me how to get this working?

Below is the code I have tried adding to the Postbit Legacy Template:


<if condition="$post['field11']"><div class="smallfont">$post<img src="/images/misc/[field11].gif" /></div></if>

I think it should be

<if condition="$post['field11']"><div class="smallfont"><img src="/images/misc/$post[field11].gif" /></div></if>

Thamelas
01-19-2009, 01:57 PM
I think it should be

<if condition="$post['field11']"><div class="smallfont"><img src="/images/misc/$post[field11].gif" /></div></if>


That doesn't work either.

Spank
01-19-2009, 02:04 PM
What's happening with it?

Thamelas
01-19-2009, 02:07 PM
Nothing. It doesn't post anything. It should be appearing right below the administrator title but it doesn't.

Here's a link:

http://www.wowguideonline.com/forum/showthread.php?p=959#post959

Spank
01-19-2009, 02:24 PM
Looks like the code is fine, just the image is no there.

http://www.wowguideonline.com/images/misc/Alliance.gif

make sure the image is in that location

Thamelas
01-19-2009, 02:26 PM
Yes it is. See:

http://www.wowguideonline.com/forum/images/misc/Alliance.gif

and the other option:

http://www.wowguideonline.com/forum/images/misc/Horde.gif

--------------- Added 1232382669 at 1232382669 ---------------

I got it to work, but i had to put the full URL of the graphic in. Any way to shorten it?


<if condition="$post['field11']"><div><img src="http://www.wowguideonline.com/forum/images/misc/$post[field11].gif" /></div></if>

Spank
01-19-2009, 02:33 PM
You might be able to just have /forum/images/misc/$post[field11].gif

not too sure on that, but if it's working, that's the main thing.

Thamelas
01-19-2009, 02:45 PM
I think I'll leave it as it is. Like you said its working and that's all that matters. Thanks for your help.