String Operator:
In PHP there are only two operators are available for strings, first one is "." operator, and another is ".= " operator. Basically both does the same but with a little difference.
First operator concatenates the first value/variable with the next one and second operator appends the argument on the right side to left side of the operator.
Example:
<?php
$a
="rose";echo
"Value of a is =". $a."<br/>";$a
.="india";echo
"After concatenation:<br/>";echo
"Value of a is =". $a;?>
Output:
Value of a is =rose
After concatenation:
Value of a is =roseindia
Example:
<?php
$a
="rose";$b
="india";echo
$a.$b;?>
Output:
roseindia
Example:
<?php
echo
"rose"."india";?>
Output:
roseindia
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.