Home >Backend Development >PHP Tutorial >Use echo!
echo() function outputs one or more strings.
can output the value of the string variable ($str):
$str = "hello world"; echo $str;echo() function is slightly faster than print().
$str1 ="hello"; $str2 = "world"; echo $str1." ".$str2;
$arr = array("bill"=>"35"); echo "bill is ".$arr['bill']." years old.";How to use multiple parameters:
echo 'This ','string ','was ','made ','with multiple parameters.';
$color = "red"; echo "Roses are $color"; echo "<br>"; echo 'Roses are $color';For other applications, please refer to: http://www.w3school.com.cn/php/func_string_echo.asp;