Is using curly braces in variables good practice in php
10:18 14 Sep 2011

Some developers uses curly braces in their PHP code and some simply concatenates them.

For example, these 2 lines of code are totally valid in PHP

echo "

{$row['title']}

"; echo "

" . $row['title'] . "

";

The output of the code is the same at the end end but which one is consider a good coding practice?

Thank you, J

php coding-style