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?
<html>
<?php $subdom="news";?>
<a href="http://www.google.com/"<?php echo $subdom;?>>google</a>
</html>
you will want to add the domain before the closing quotation sign to append it to the href variable instead of just adding it into the a tag.