PHP – Concatenate Strings

String Concatenation

To concatenate, or combine, two strings you can use the . operator:

Example

$x = "Hello";
$y = "World";
$z = $x . $y;
echo $z;

The result of the example above is HelloWorld, without a space between the two words. Continue reading PHP – Concatenate Strings