jedimastermopar
11-21-2006, 03:29 PM
I have a calulation and if the reult is zero I don't want to display anything..but here are my results. Where is the 0 comming from when the result is 0?
item2tot = 200
Statement 1
<?php if ($item2tot != '0'){ echo "value = $item2tot" ;} ?>
Output
value = 200
item2tot = 0
Statement 1
<?php if ($item2tot != '0'){ echo "value = $item2tot" ;} ?>
a 0 is displayed no value =
Output
0
item2tot = 200
Statement 1
<?php if ($item2tot != '0'){ echo "value = $item2tot" ;} ?>
Output
value = 200
item2tot = 0
Statement 1
<?php if ($item2tot != '0'){ echo "value = $item2tot" ;} ?>
a 0 is displayed no value =
Output
0