What is the correct syntax for concatenating variables in a string in PHP?

When concatenating variables in a string in PHP, you can use the dot (.) operator to combine the variables with the string. This allows you to include dynamic values within a static string. Make sure to enclose the entire expression within double quotes to allow for variable interpolation.

// Example of concatenating variables in a string in PHP
$name = "John";
$age = 25;

echo "Hello, " . $name . "! You are " . $age . " years old.";