PDA

View Full Version : How to make the rank icon a link


wacnstac
05-19-2004, 10:59 PM
Hi, I need a hack to make the rank icon a hyperlink but only want to do it for one particular rank. What sort of if statement do I need and what template has the html for this?

Pseudomizer
05-20-2004, 01:06 AM
Hi, I need a hack to make the rank icon a hyperlink but only want to do it for one particular rank. What sort of if statement do I need and what template has the html for this?

Hi,

go to your forum options and enable HTML Template header in the source code. After having done this go to the specific forum php site and open the source code. Look in the source code in which template your graphic is located by looking for the start of the last applet before the graphic starts.

When you found this then just use a standard <if condition statement which is described in many many threads here to define what should happen if....

Cheers,

wacnstac
05-20-2004, 01:35 AM
Ok, here's what I need to modify in the Postbit template:

<if condition="$post['usertitle']">
<div class="smallfont">$post[usertitle] </div>
</if>

<if condition="$post['rank']">
<if ???>
<div class="smallfont">$post[rank]</div>
</if>
</if>

I just don't know what in the heck to put in the if statement.

wacnstac
05-21-2004, 01:49 AM
Can anybody help a brother out here?

kall
06-10-2004, 06:34 AM
Can anybody help a brother out here?

It's a template modification..but:

In postbit_legacy

Find:


<if condition="$post['rank']"><div class="smallfont">$post[rank]</div></if>


Replace with:


<if condition="$post[usergroupid] == XXX"> <div class="smallfont"><a href="subscriptions.php?"><img src="forums/images/ranks/rankimage.gif" border="0" alt="Rank Type" /></a></div>
<br />
<else />

<if condition="$post['rank']"><div class="smallfont">$post[rank]</div></if></if>


Replace XXX with the usergroup number that relates to this Rank image and change the path to the image...obviously. :)

wacnstac
06-11-2004, 01:02 AM
I tried this and no workie. In fact it didn't seem to make any difference no matter what I did:


<if condition="$post[membergroupids] == 94">
<div class="smallfont"><a href="subscriptions.php?"><img src="forum/images/ranks/sponsor.gif" border="0" alt="Rank Type" /></a></div><br />
<else />
<if condition="$post[membergroupids] == 99">
<div class="smallfont"><a href="subscriptions.php?"><img src="forum/images/ranks/sponsor.gif" border="0" alt="Rank Type" /></a></div><br />
<else />
<if condition="$post['rank']"><div class="smallfont">$post[rank]</div></if></if></if>

weird!

kall
06-12-2004, 07:14 AM
I tried this and no workie. In fact it didn't seem to make any difference no matter what I did:


<if condition="$post[membergroupids] == 94">
<div class="smallfont"><a href="subscriptions.php?"><img src="forum/images/ranks/sponsor.gif" border="0" alt="Rank Type" /></a></div><br />
<else />
<if condition="$post[membergroupids] == 99">
<div class="smallfont"><a href="subscriptions.php?"><img src="forum/images/ranks/sponsor.gif" border="0" alt="Rank Type" /></a></div><br />
<else />
<if condition="$post['rank']"><div class="smallfont">$post[rank]</div></if></if></if>

weird!
If you look carefully at what I wrote, and then at what you wrote, either you didn't try that, or you typoed in your last post.

I have: <if condition="$post[usergroupid] == XXX">

You have: <if condition="$post[membergroupids] == 94">

In case you can't see the difference, I am using a conditional that works for postbit_legacy, your one does not.

That might be the reason why your one doesn't work, and mine does.