Vad använder ni? Echo eller print när ni skriver ut något? Enligt en php-lärare jag haft så ska man inte använda echo av flera anledningar. Dock minns ja dem inte så bra hehe ... Minns att print är bättre för det är en riktig funktion och fungerar då på nå sätt bättre .... nå ni funderat och hört nått om??
Skillnaderna är ytterst marginella. Så här står det i manualen
För echo:
echo ( string arg1 [, string argn...])
Outputs all parameters.
echo() is not actually a function (it is a language construct) so you are not required to use parentheses with it. In fact, if you want to pass more than one parameter to echo, you must not enclose the parameters within parentheses. It is not possible to use echo() in a variable function context, but you can use print() instead.
För print:
print ( string arg)
Outputs arg. Returns TRUE on success, FALSE on failure.
print() is not actually a real function (it is a language construct) so you are not required to use parentheses with it.