0

When I run locally:

function sayHello($name) { 
    echo 'Hello $name';
}

sayHello('Lucas');

what I get in the browser is Hello $name. I know "Hello " . $name; will do but I am just curious because it is working fine for the guy on youtube, it is showing the right result for him.

I am running PHP 7.1 in MAMP and MacOS.

Labanino
  • 3,902
  • 9
  • 33
  • 51
  • @John Conde, I didn't know what the problem was. If you don't know the difference how can you ask the right question? Thanks – Labanino Jan 11 '19 at 20:47
  • That's why we have the duplicate questions. So we only have to explain it once and can point users to it whenever they have the same issue but didn't know what to ask. – John Conde Jan 11 '19 at 20:49

0 Answers0