vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Reputation points in postbit (https://vborg.vbsupport.ru/showthread.php?t=136117)

yuriy 01-10-2007 05:49 PM

Reputation points in postbit
 
1 Attachment(s)
Hey everyone, ANOTHER HELP is needed lol, I'm a n00b at vB for NOW!, I was with that stupid php-nuke for couple of years, until I found vB can be better than that crap, anyways this is what I want:

When a user has 0 reps I will change this to be on register get no points, and as you can see in the image below it shows Reputation: 0 in red color and when theres a rep above 0 it shows Reputation: 15 in green color, I currently have this in my post bit:

PHP Code:

<if condition="$show['reputation']"><div><if condition="$show['reppower']"></if>
<
table width="120" border="0" cellspacing="0" cellpadding="0">
<
tr>
<
td width="48" height="20" align="left" background="images/reputation/pointrep.gif"><span class="smallfont">Reputaion$post[reputation]</span></td>
</
tr>
</
table></if> 

I have no idea how to get this to work I want it to, please help, Thank you so much guys! vBulletin's help is much faster then nukes :\ Thanks again everyone! :)

:eek: Almost forgot :) check the image below if you didn't understand what I was trying to say :p

magnus 01-11-2007 11:25 AM

Quote:

Originally Posted by yuriy (Post 1155648)
When a user has 0 reps I will change this to be on register get no points, and as you can see in the image below it shows Reputation: 0 in red color and when theres a rep above 0 it shows Reputation: 15 in green color, I currently have this in my post bit:

AFAIK, this can be done with simple conditionals.

ie.
PHP Code:

<span style="color: <if condition="$post['reputation'] > 0">green<else />red</if>">$post[reputation]</span

Something like that should work..

yuriy 01-11-2007 01:18 PM

How about this, here is my code I modified yours:

PHP Code:

<span class="smallfont">Reputation: </span><span class="smallfont" style="color: <if condition="$post['reputation'] > 0">green<else />red</if>"><b>$post[reputation]</b></span

How would I go about lets say um, if 0 its red, if above 0 its green, if above 1,000 its yellow, if above 2,000 its orange, and so on.. can someone help me get this? please


All times are GMT. The time now is 08:34 PM.

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

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01297 seconds
  • Memory Usage 1,734KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (3)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete