Exploding Garrmondo Weiner Interactive Swiss Army Penis

Exploding Garrmondo Weiner Interactive Swiss Army Penis (http://www.gamingforce.org/forums/index.php)
-   Help Desk (http://www.gamingforce.org/forums/forumdisplay.php?f=36)
-   -   vBulletin thread prefix help (http://www.gamingforce.org/forums/showthread.php?t=39732)

Krelian Jan 20, 2010 11:34 PM

vBulletin thread prefix help
 
I've just installed a thread prefix product on my forums—the same one GFF uses, seemingly—and everything's fine and dandy. However, I can't figure out how the hell to use images for thread prefixes instead of plain text (just like GFF's system). No explanation of how to achieve this exists in the documentation, nor does the UI hint at it being possible.

I'd be extremely grateful if someone could reveal how exactly to do this. Cheers in advance.

Bigblah Jan 21, 2010 05:58 AM

Do you recall having to update an assload of templates (to insert the prefix text)? Yeah, you gotta edit them again to change it into images.

For example, instead of inserting <b>$prefix</b> or something, change it into <img src="upload/your/crap/here/$prefix.gif" alt="$prefix" />.

(Change it only for the thread and post displays, not on the administration side).

And, of course, name your images after the prefixes and upload them.

Krelian Jan 21, 2010 11:12 PM

Awesome - cheers for the help, Blah.

I've looked through all the templates I had to alter, and can't figure out which segments of code to replace. I'm having a hard time locating the relevant string — however, I found this bit of code I added to the forumdisplay template:

Code:

<if condition="$show['threadprefix']">
                        <td colspan="2" class="smallfont">&nbsp;</td>
                </tr>
                <tr>
                        <td class="smallfont">$vbphrase[threadprefix]:</td>
                        <td>$threadprefixes</td>
                        </if>
                        <td class="smallfont" align="$stylevar[right]" style="padding-top:$stylevar[cellpadding]px">
                                <input type="submit" class="button" value="$vbphrase[show_threads]" />
                        </td>
                </tr>

Would changing $threadprefixes to <img src="imagedirectory/$threadprefixes.gif" alt="$threadprefixes" /> do the trick, or am I barking up the wrong tree? Also, do I need to change any templates other than forumdisplay (as it's the only one the images will actually displayed in), or will I have to go through all the other changed templates in a similar fashion?

Bigblah Jan 22, 2010 12:13 AM

Yeah, that looks like it. You only need to change it for forumdisplay (and maybe showthread if you want).

Krelian Jan 22, 2010 11:18 AM

Hm. I've tried a bunch of changes (including the one above) and nothing's working. Would it be too much to ask to take a peek at how it's done in GFF's forumdisplay?

Krelian Jan 23, 2010 11:30 PM

Never mind; I figured it out — it was as simple as changing the forum HTML markup to <img src="http://www.gamingforce.org/forums/images/prefixes/${1}.gif" alt="{1}" /> (where {1} is rendered as the name of the prefix). Didn't need to edit any templates or anything. Goddamn I'm stupid.

Bigblah Jan 24, 2010 03:17 AM

Looks like you're using a different plugin, I guess.

Also host the images yourself :p

Krelian Jan 24, 2010 08:10 AM

What the fuck, it rendered "/images/prefixes" with the rest of the GFF URL simply because it was wrapped in HTML (despite being unparsed). I AM BEING MADE TO LOOK SILLY :mad:


All times are GMT -5. The time now is 02:16 AM.

Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2025, vBulletin Solutions, Inc.