OJS 3.4.0 css problem

Describe the issue or problem
Sometimes css not loaded and show binary.

Steps I took leading up to the issue
For example:

  1. Go to website
  2. Force refresh / clear cache
  3. Css error

What application are you using?
OJS 3.4.0

Additional information

This problem randomly appear, when open new private window and load the web, css sometimes show binary.


Sometimes not.

Hi @anasfanani,

Can you share with me (via private message if you’d prefer) the URL to your journal?

Regards,
Alec Smecher
Public Knowledge Project Team

1 Like

Yes, I share the URL via private message.

Hi @anasfanani,

Unfortunately I can’t make any sense out of the binary contents you shared – it doesn’t look like anything I recognize. I would recommend checking your installation to make sure none of the files have been modified. To do this, download a copy of OJS 3.4.0 of the same version you’re using, and use a tool like diff to compare its contents against what you have deployed.

Regards,
Alec Smecher
Public Knowledge Project Team

1 Like

I am pretty sure all files are original, because I use git on my site to detect any changes.
Using this latest release file https://pkp.sfu.ca/ojs/download/ojs-3.4.0-7.tar.gz

On my localhost server, everything works, checked with curl many times, but sometimes errors occur when on public domain.

Maybe this problem occur because I use cloudflare, but it becomes more challenging because the problem appears randomly.

Hi @anasfanani,

Hmm, I’m afraid I don’t have anything to recommend – the only cases I’ve seen where parts of OJS occasionally serve up other content is when they’ve been hacked to occasionally serve spam, but if you’re tracking with git (and hosting in a safe configuration – e.g. files_dir not publicly available), that should be easy to detect.

Do you have compression enabled on your web server e.g. using mod_deflate or similar? Just asking because the binary content resembles compressed data – it is just about uncompressible, based on a quick test with gzip.

Regards,
Alec Smecher
Public Knowledge Project Team

1 Like

The first thing I do is disable any non-standard cloudflare configuration back to default and enable development mode in cloudflare.

Check again multiple times with curl; the problem still appears randomly, then try bypassing Cloudflare with curl --resolve; the problem still exists in my public site, trying to compare server configuration on local and public, then I found out the nginx PageSpeed module caused this problem.

Thank you Alec Smecher for your help.

1 Like