String Creation using Single Quotes
Earlier,We are aware of creation of strings using double-quotes but you can create the string using single-quotes, But you need to care about some characters which can create some problem .
For example,if you created a string in which you got a single apostrophe then you have to use some defined symbol to display the desired output.
Code:
$Str_var = 'Its the magic of Programming .....';
echo 'Its the magic of Programming .....';
echo $Str_var;
If you include some apostrophe then you need to use the escape (\) like
Code:
echo 'It\'s the magic of Programming .....';
Bookmarks