0

Some of my css files and most of my js files are not loading

I started having problems after a Windows update last week. Since then I have reinstalled my server stack a couple of times, but still have the problem.

Using invoke-WebRequest in a power shell (e.g. invoke-WebRequest -Uri http://localhost/CSS/ui.jqgrid.css). I have found that css files are not loading if they are greater than about 10kb.

I took a large file and cut it down to the size of one that was loading ok and it then loaded. I converted it to CR/LF line endings which took it over the 10k and it failed. I then removed a few lines and it loaded again so it is definitely a size issue. I suspect the same thing is happening with .js files.

Is there a limit setting I need to add to nginx.conf or php.ini?

Reading some of the answers to similar past questions most talk seems to be about browser limitations but no mention of server settings. I have tried in Chrome and Edge but get the same problem.

Error message from invoke-webrequest when css file size>10kb is:

invoke-WebRequest : The underlying connection was closed: An unexpected error occurred on a receive.......

Typical error seen in web browser dev tools is:

Failed to load resource: net::ERR_CONNECTION_RESET

mullac
  • 693
  • 6
  • 17
NormB
  • 41
  • 5
  • `php.ini` should not effect loading `js` or `css` - so that leaves `nginx.conf` as a possible source of limit. However, in my experience, there is no limit to the size of a file that nginx will send, and quite honestly, I can't see any setting in nginx that could be used to impose a download limit (only upload limits) – Bravo Oct 03 '19 at 23:27
  • check the nginx error logs on the server - perhaps there's something helpful there. Have you tried Firefox by any chance? – Bravo Oct 03 '19 at 23:33
  • This ? https://stackoverflow.com/questions/10075304/nginx-fails-to-load-css-files – Nic3500 Oct 04 '19 at 03:40
  • nothing relevant in error log Same result in Firefox I have also noticed that when I run phpinfo() all I get is the first block of output, as far as "Additional .ini files parsed " and then nothing until I then see "Failed to load resource: net::ERR_CONNECTION_RESET phpinfo.php:1" in the DevTools console - does that give any clues? – NormB Oct 04 '19 at 11:22

0 Answers0