PDA

View Full Version : show style postbit


Vb-Hispano
02-08-2004, 02:11 PM
Hello, how could i do that apear in thee postbit of any users the style what is using?

Vb-Hispano
02-08-2004, 02:53 PM
sorry deleted thanks

Logikos
02-10-2004, 04:50 PM
<b>Style:</b>
<if condition="$post[styleid]==1"><a href="$vboptions[forumhome].php?$session[sessionurl]&styleid=$post[styleid]">Style 1</a></if>

<if condition="$post[styleid]==2"><a href="$vboptions[forumhome].php?$session[sessionurl]&styleid=$post[styleid]">Style 2</a></if>

<if condition="$post[styleid]==3"><a href="$vboptions[forumhome].php?$session[sessionurl]&styleid=$post[styleid]">Style 3</a></if>

<if condition="$post[styleid]==4"><a href="$vboptions[forumhome].php?$session[sessionurl]&styleid=$post[styleid]">Style 4</a></if>

Try that.

sabret00the
02-10-2004, 09:35 PM
wouldn't it be easier to hack is using a query?

ie
in showthread have
$post_styleid = SELECT styleid FROM post
$post_stylename = SELECT stylename FROM post WHERE styleid = $post_styleid
and then just have in the template <b>style:</b> <if condition="$post[styleid]==$post_styleid">$post_stylename</if>

Logikos
02-10-2004, 09:37 PM
Why add another query to the 80 vb3 has as a default, when the template systems already supports what he needs to do.

sabret00the
02-10-2004, 09:38 PM
cleaner template :shrugs:

Logikos
02-10-2004, 09:43 PM
cleaner template :shrugs:lol, both would work, but i try to minimize the amount of querys i need to load. I would suggest adding a few extra lines in the template. Can Easily be done.

sabret00the
02-10-2004, 09:46 PM
heh i just realised this is the vB2 forums lol

Brad
02-11-2004, 06:38 AM
It is not possible to do this in vB 2 without hacking the board, well you can show the style id a user is using but you can not get the style name.

Logikos
02-12-2004, 08:05 AM
i just relized this is in the vb2 section, stupid me. ^^