title: add a php variable within a href link
body: <p>so I need to make a variable sub-domain to add to the end of a domain but it is not recogising the variable. in this example it would just go to google.com. anyone know the correct way of doing this?</p>
  
  <pre><code>&lt;html&gt;
  
    &lt;?php $subdom="news";?&gt;
  
       &lt;a href="http://www.google.com/"&lt;?php echo $subdom;?&gt;&gt;google&lt;/a&gt;
  &lt;/html&gt;
  </code></pre>