Php function in echo? Is it possible?

Fuvitas

New Member
Hi I have a special problem ... I have three values from database.\[code\]Value1 is 1 or 0Value2 is again 1 or 0Value3 is remaining time like (24 hours left, 23, ...)\[/code\]There valies are saved in variables:\[code\]$value1$value2$value3\[/code\]These values are changing from DB every load from webpage. I have these values also in echo""; in php function already like:\[code\]echo"text text text ................."Value 1 is:" . $value1 . " and value 2 is:" . $value2 . ""..................;\[/code\]What I need is a function that says fifferent thing like\[code\]if (value1=0)echo "Only text"elseecho "Value 1 is:" . $value1 . " and value 2 is:" . $value2 . ""; \[/code\]this to be in another echo function from first example so in my way it looks like this:\[code\]*Some function*echo"if (value1=0)echo "Only text"elseecho "Value 1 is:" . $value1 . " and value 2 is:" . $value2 . """; // two echo closing \[/code\]but it does not worky any help here please how to solve this? thank you :-)
 
Back
Top