Hello,

I am having website error that I still do not know what causes it. In several of my users browsers (firefox), some words in the website content that I build turn into a blue link and also there is a Java ads in it.

Another one, index.html turns into index.css and the user cannot browse the website. Page not found. Other websites work just fine.

Any clue why? And what's the solution?

I code the website using pure PHP without any framework.

I am having website error that I still do not know what causes it. In several of my users browsers (firefox), some words in the website content that I build turn into a blue link and also there is a Java ads in it.

Another one, index.html turns into index.css and the user cannot browse the website. Page not found.

It seems that some code was injected into your website. Check the source of the pages and the contents of Javascript and CSS files. Sometimes, these attacks happens through the FTP client, for example:

You're using filezilla, the passwords are saved in clear into an XML file, if a worm or a virus reads the contents of this file, it can connect to the remote web server and inject code, rewrite and delete files.

If your computer is virus free, then it could be your client computer, or a previous developer computer. It's reasonably to think it's not related to your computer, otherwise you would see this problem in all your websites, perform the check anyway. Sometimes the password is not changed for years, a bad practice that expose to these kind of issues.

If you cannot check the logs of the webserver then open a ticket to the hosting and ask them to check. If they confirm the problem comes from FTP, then you must ask for a password change otherwise the virus will overwrite the website again.

So, to repeat:

  1. check the logs
  2. if confirmed it was through FTP, ask password change
  3. scan your system with an updated antivirus
  4. replace the current website with your backup copy
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.