CodeIgniter Forums
When it comes to echoing or setting do you prefer ' or " - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: When it comes to echoing or setting do you prefer ' or " (/showthread.php?tid=5480)

Pages: 1 2


When it comes to echoing or setting do you prefer ' or " - El Forum - 01-23-2008

[eluser]Craig A Rodway[/eluser]
It does. But I read somewhere that curly braces was quicker - I just can't find the site again that seemed to think it was. Smile


When it comes to echoing or setting do you prefer ' or " - El Forum - 01-23-2008

[eluser]wiredesignz[/eluser]
But if I take off my braces my pants will fall down. Tongue


When it comes to echoing or setting do you prefer ' or " - El Forum - 01-23-2008

[eluser]Sarre[/eluser]
Combined with a too heavy pageload, you might not make it to the little room :ohh:

:-p


When it comes to echoing or setting do you prefer ' or " - El Forum - 01-23-2008

[eluser]Michael Wales[/eluser]
I use single quotes and concatenations unless I need a newline, tab character, or CI's routing.

Code:
$str = 'World';
$str2 = 'Hello ' . $str;
$str3 = $str2 . "\n";
$route['page/:any'] = "page/view/$1";