Concatenate string in echo statement in PHP

Description

The following code shows how to concatenate string in echo statement.

Example


<?php
  echo "First string", 2, 3.4, "last string";
?>

The code above generates the following result.





















Home »
  PHP Tutorial »
    Development »




Environment
Error
Hash
Include
Locale
Math
Network
Output
Reflection
PHP Regular Expressions