0

why use echo for print statement?

can I use print keyword

16th Jul 2016, 7:06 AM
Amit
Amit - avatar
2 odpowiedzi
+ 2
doesn't really matter what to use. there is a discussion ongoing for years now about what Best, which one is faster, more secure and so on. but in the end they are more or less the same. what differs is. echo does not have a return value while print has a return value of 1. and echo can contain multiple Parameters like echo "string1", "string2", ....; while print only can hold 1 Argument.
16th Jul 2016, 9:58 AM
Steven
Steven - avatar
+ 1
Steven is right but remember that echo is a bit faster than print.
2nd Nov 2016, 4:05 PM
Hasan Al-Yazidi
Hasan Al-Yazidi - avatar