I am seeing this error on front page of one of my website

Parse error: syntax error, unexpected '< 

Some code has been hidden for security* but the source of that error is index.php. On examining my index.php i see a line of code referncing index_old.php. The code on the that file is as shown





       fwrite($fp2," ".$_SERVER["SERVER_ADDR"]."    ".$_SERVER["HTTP_HOST"]); 

       fwrite($fp2," ".$_SERVER['HTTP_USER_AGENT']);

       fwrite($fp2," ".strftime('%c')."\r\n");


I am cracking my head to find out if the site has been infiltrated or injected with suspicious scripts. Could anyone help me figure out this?


1 Answer 1


A bunch of have have posted numerous answers on Joomla Stack Exchange about what to to in case of a site being hacked.

My suggestion first would be to delete the index_old.php file, then remove the reference to this file in the index.php.

Then have a read of these:

A quick summary:

  • Update Joomla to latest version (currently 3.5.1)
  • Update ALL extensions to their latest version
  • Change your password for the hosting control panel, FTP and Joomla super user
  • Ensure chmod permissions for is 755 for directories and 644 for files
  • Seems like i cannot get around this problem. Again i am seeing this error
    – Muteshi
    Commented Apr 10, 2016 at 18:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.