I am trying to setup a template system with a header.php and footer.php. That way I can just update the header and footer php files to update the entire site. It worked fine until I added the following to put a unique page title and keywords for each page. This is the error I am getting: Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ',' or ';' in /home/bans1/public_html/header.php on line 28 PHP: Here is line 27 and 28 <?php if (isset($description)) { echo "<meta name=\"description\" content=\"".$description"\">";}?> PHP: Your help is appreciated. Thanks, AC
<?php if (isset($description)) { echo '<meta name="description" content="'.$description.'">'; } ?> PHP:
you're missing concatenation dot after $description variable <?php if (isset($description)) { echo "<meta name=\"description\" content=\"".$description."\">";}?>