6.3. String OperatorsThere are only two string operators in PHP: concatenation and shorthand concatenation . Both are shown in Table 6-3.
These operators are used to join strings together, like this: $first = "Hello, "; $second = "world!"; // join $first and $second; assign to $third $third = $first . $second; // $third is now "Hello, world!" $first .= " officer!"; // $first is now "Hello, officer!" |