WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Syntax error unexpected (3 posts)

  1. hkoster
    Member
    Posted 9 months ago #

    Dear WordPress,

    I tried to change the code to include a video in the custom header in and I received the following message Parse error: syntax error, unexpected '<' in /var/www/vhosts/trndmrkr.com/httpdocs/wp-content/themes/renkon/inc/custom-header.php on line 12.

    After this tried to change back to the original code again (and save the original code), but I keep getting the error message.Further more I cannot log in to the dashboard and it seems the e-mail linked to my site (info@trndmrkr.com) does not respond either.

    Can anyone please help me?
    My site is http://www.trndmrkr.com
    Thank you in advance!

  2. Shaun Scovil
    Member
    Posted 9 months ago #

    Best to never edit your theme files from WP-Admin > Appearance > Editor. If you do that and you make a mistake, you will not be able to access the admin area.

    You'll want to edit your theme files via FTP or (if your web host has it) the cPanel > File Manager. Do that and you can fix your mistake, then you will be able to access the admin area again.

    The error you were getting was probably caused by putting HTML inside of PHP tags, like this:

    <?php
        // some PHP code
    
        <img src="//example.com/my-image.png" />
    
        // more PHP code
    ?>
  3. hkoster
    Member
    Posted 9 months ago #

    Hi Shaun, thanks I'll solve it on the FTP!

Reply

You must log in to post.

About this Topic