title: How exactly Heredoc handles curly braces?
body: <p>I was using the PHP Heredoc and found something that was a bit confusing for me, maybe a bug or maybe I'm just a rookie.</p>
  <p>So here is what confusing for me:</p>
  <pre><code>echo &lt;&lt;&lt;TEXT
           &lt;img src=&quot;images/achivements/{$achievement_id}.png&quot; alt=&quot;{$achievementName}&quot;&gt;
       TEXT;
  </code></pre>
  <p>I thought this would return something like:</p>
  <blockquote>
  <p><code>&lt;img src=&quot;images/achivements/idOfAchievement.png&quot; alt=&quot;nameOfTheAchievement&quot;&gt;</code></p>
  </blockquote>
  <p>but it returns:</p>
  <blockquote>
  <p><code>&lt;img src=&quot;images/achivements/{idOfAchievement}.png&quot; alt=&quot;nameOfTheAchievement&quot;&gt;</code></p>
  </blockquote>
  <p>It leaves the curly braces inside the <code>src=&quot;&quot;</code> and removes it at the <code>alt=&quot;&quot;</code></p>
  <p>So a solution would be something like this:</p>
  <pre><code>echo &lt;&lt;&lt;TEXT
           &lt;img src=&quot;images/achivements/$achievement_id.png&quot; alt=&quot;{$achievementName}&quot;&gt;
       TEXT;
  </code></pre>
  <p>Is there an explanation why it works like this?</p>
  <p>Thank you for reading this and have a good day!</p>