Programming Code Center(PCC)
[PHP]

(PCC)::[How-to-Display-strings-and-variables-with-the-print-command-in-php]::[php]

File Name : index.php

<!DOCTYPE html>
<html>
<body>

<?php
$txt1 = "Learn PHP";
$txt2 = "W3Schools.com";
$x = 5;
$y = 4;

print "<h2>" . $txt1 . "</h2>";
print "Study PHP at " . $txt2 . "<br>";
print $x + $y;
?>

</body>
</html>

Output :

" . $txt1 . ""; print "Study PHP at " . $txt2 . "
"; print $x + $y; ?>