• Why do I get a syntax error when adding a link with the url of the site? Thanks

    Parse error: syntax error, unexpected T_STRING in /wp-content/themes/one/functions.php on line 29

    $default_footer_content = "<a href='#'>Contact Us</a> | <a href='#'>Trademarks</a> | <a href='#'>Privacy Statement</a><br />&copy; 2009 - ".date('Y')." <a href="bloginfo('siteurl')">".get_bloginfo('name')."</a>. All Rights Reserved.";

Viewing 4 replies - 1 through 4 (of 4 total)
  • There is probably something in the footer.php of your theme that brings in the default_footer_content. It also looks like the code you added (the link to your site) is outside of the quotes and therefore not part of the default_footer_content.

    Usually if the footer is coded into functions.php it is a copyright protection that the theme author doesn’t want you to remove.

    Thread Starter Copywrite

    (@copywrite2012)

    Thanks Jonas I worked it out

    $default_footer_content = "<a href='#'>Contact Us</a> | <a href='#'>Terms of Use</a> | <a href='#'>Trademarks</a> | <a href='#'>Privacy Statement</a><br />&copy; 2009 - ".date('Y')." <a href='bloginfo('siteurl');'>".get_bloginfo('name')."</a>. All Rights Reserved.";

    Great. Looks like <a href='bloginfo('siteurl');'> is what made the difference.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Syntax error when adding link with site url’ is closed to new replies.