drisate Posted December 27, 2008 Share Posted December 27, 2008 Hey guys i am trying to do this $st['3']="Agility"; $st['4']="Strength"; $st['5']="Intellect"; $st['6']="Spirit"; $st['7']="Stamina"; $st['12']="Defense"; $st['13']="Dodge"; $st['14']="Parry"; $st['15']="Block"; $st['35']="Resilience"; $st['31']="Hit Rating"; $st['33']="Hit Avoidance"; $st['32']="Hit Crit Rating"; $st['34']="Hit Crit Avoidance"; $st['36']="Hit Haste Rating"; $st['16']="Melee Hit Rating"; $st['19']="Melee Crit Rating"; $st['22']="Melee Hit Avoidance"; $st['25']="Melee Crit Avoidance"; $st['28']="Melee Haste Rating"; $st['17']="Ranged Hit Rating"; $st['20']="Ranged Crit Rating"; $st['23']="Ranged Hit Avoidance"; $st['26']="Ranged Crit Avoidance"; $st['29']="Ranged Haste Rating"; $st['18']="Spell Hit Rating"; $st['21']="Spell Crit Rating"; $st['24']="Spell Hit Avoidance"; $st['27']="Spell Crit Avoidance"; $st['30']="Spell Haste Rating"; if ($items[stat_value1]!="0"){$desc=$desc.$st[".$items[stat_type1]."].": $items[stat_value1]<br>";} if ($items[stat_value2]!="0"){$desc=$desc.$st[".$items[stat_type2]."].": $items[stat_value2]<br>";} if ($items[stat_value3]!="0"){$desc=$desc.$st[".$items[stat_type3]."].": $items[stat_value3]<br>";} if ($items[stat_value4]!="0"){$desc=$desc.$st[".$items[stat_type4]."].": $items[stat_value4]<br>";} if ($items[stat_value5]!="0"){$desc=$desc.$st[".$items[stat_type5]."].": $items[stat_value5]<br>";} if ($items[stat_value6]!="0"){$desc=$desc.$st[".$items[stat_type6]."].": $items[stat_value6]<br>";} if ($items[stat_value7]!="0"){$desc=$desc.$st[".$items[stat_type7]."].": $items[stat_value7]<br>";} if ($items[stat_value8]!="0"){$desc=$desc.$st[".$items[stat_type8]."].": $items[stat_value8]<br>";} if ($items[stat_value9]!="0"){$desc=$desc.$st[".$items[stat_type9]."].": $items[stat_value9]<br>";} if ($items[stat_value10]!="0"){$desc=$desc.$st[".$items[stat_type10]."].": $items[stat_value10]<br>";} But when stat_value is not equal to 0 or nothing $st[".$items[stat_type10]."]. returns nothing When i echo $desc i get : 14<br> instead of Strength: 14<br> is something wrong with $st[".$items[stat_type10]."]? Quote Link to comment Share on other sites More sharing options...
drisate Posted December 27, 2008 Author Share Posted December 27, 2008 found it if ($items[stat_value1]!="0"){$desc=$desc.$st[$items[stat_type1]].": $items[stat_value1]<br>";} if ($items[stat_value2]!="0"){$desc=$desc.$st[$items[stat_type2]].": $items[stat_value2]<br>";} if ($items[stat_value3]!="0"){$desc=$desc.$st[$items[stat_type3]].": $items[stat_value3]<br>";} if ($items[stat_value4]!="0"){$desc=$desc.$st[$items[stat_type4]].": $items[stat_value4]<br>";} if ($items[stat_value5]!="0"){$desc=$desc.$st[$items[stat_type5]].": $items[stat_value5]<br>";} if ($items[stat_value6]!="0"){$desc=$desc.$st[$items[stat_type6]].": $items[stat_value6]<br>";} if ($items[stat_value7]!="0"){$desc=$desc.$st[$items[stat_type7]].": $items[stat_value7]<br>";} if ($items[stat_value8]!="0"){$desc=$desc.$st[$items[stat_type8]].": $items[stat_value8]<br>";} if ($items[stat_value9]!="0"){$desc=$desc.$st[$items[stat_type9]].": $items[stat_value9]<br>";} Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.