Issue with simple text framing
<p>Basically, I'm trying to create a frame around text and on the third line where the text goes, it doesn't print out the # that's supposed to be the "padding" around it.</p>

<pre><code>******************
*################*
*#HELLO, JUSTIN!*
*################*
******************
</code></pre>

<p>That's what it looks like - after the ! in the $greeting variable, there should be a #. The code is below, could anyone explain why this happens?</p>

<pre><code>&lt;html&gt;
&lt;body&gt;&lt;?php
    $pad = 1;
    $rows = ($pad * 2) + 3;
    $greeting = "HELLO, JUSTIN!";
    $col = strlen($greeting) + (2 * $pad) + 2;


for ($r = 0; $r != $rows; ++$r)
{
    for ($c = 0; $c != $col; ++$c)
    {
        if ($r == $pad + 1 &amp;&amp; $c == $pad + 1)
        {
            echo $greeting;
            $c += strlen($greeting);
            //echo "#";
        }
        else 
        {
            if ($r == 0 || $r == $rows - 1 || $c == 0 || $c == $col - 1)
                echo "*";
            else
                echo "#";
        }
    }
    echo "&lt;br /&gt;";
}
?&gt;&lt;/body&gt;
&lt;/html&gt;
</code></pre>
